Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. i seem to be having an error with QJsonObject even tho all my friends who used the same code have it working
Forum Updated to NodeBB v4.3 + New Features

i seem to be having an error with QJsonObject even tho all my friends who used the same code have it working

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 2 Posters 98 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    amrou
    wrote on last edited by
    #1

    9a5c961f-e006-48fc-9872-794eb78894df-image.png
    here are the errors im getting
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:819: error: aggregate 'QJsonObject emailData' has incomplete type and cannot be defined
    ....\gemployes.cpp: In member function 'void GEmployes::envoyerMailViaBrevo(QString, QString, QString)':
    ....\gemployes.cpp:819:17: error: aggregate 'QJsonObject emailData' has incomplete type and cannot be defined
    819 | QJsonObject emailData;
    | ^~~~~~~~~
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:820: error: aggregate 'QJsonObject sender' has incomplete type and cannot be defined
    ....\gemployes.cpp:820:17: error: aggregate 'QJsonObject sender' has incomplete type and cannot be defined
    820 | QJsonObject sender;
    | ^~~~~~
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:825: error: aggregate 'QJsonObject toRecipient' has incomplete type and cannot be defined
    ....\gemployes.cpp:825:17: error: aggregate 'QJsonObject toRecipient' has incomplete type and cannot be defined
    825 | QJsonObject toRecipient;
    | ^~~~~~~~~~~
    :-1: error: [Makefile.Debug:2056: debug/gemployes.o] Error 1
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:819: error: Variable has incomplete type 'QJsonObject'
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:820: error: Variable has incomplete type 'QJsonObject'
    C:\Users\feral\Downloads\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\projetcpp-2A3-smart-football-Fatma_omar_yassine_hamza\gemployes.cpp:825: error: Variable has incomplete type 'QJsonObject'
    mind you the code has worked in 4 other laptops

    1 Reply Last reply
    0
    • A Offline
      A Offline
      amrou
      wrote on last edited by
      #2

      id like to add that

      image.png
      it is included in my libraries

      1 Reply Last reply
      0
      • Christian EhrlicherC Offline
        Christian EhrlicherC Offline
        Christian Ehrlicher
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Include the QJsonObject header in your source

        Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
        Visit the Qt Academy at https://academy.qt.io/catalog

        1 Reply Last reply
        3

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved