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. [Beginner][Transition between 2 pages] Errors by creating the second page
Forum Updated to NodeBB v4.3 + New Features

[Beginner][Transition between 2 pages] Errors by creating the second page

Scheduled Pinned Locked Moved Solved General and Desktop
7 Posts 2 Posters 261 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.
  • S Offline
    S Offline
    Shadow.01
    wrote on last edited by
    #1

    Hi all,
    I am totally new to QT system. In order to try the basics operations, I am trying to create a simple QT empty project with two forms and, in each form, a button to pass from a form to the other. That's all.

    1. I started by creating a new QT Quick Application - Empty
    2. I created the second form by Create new -> QT Designer form class -> Dialog with buttons

    Nothing else. And, at this point, I see the following error. Why? Have I do some mistakes?

    Thank you very much,

    Screenshot 2021-06-10 112824.png

    jsulmJ 1 Reply Last reply
    0
    • S Shadow.01

      Thanks for the super fast reply!

      This is the content of dialog.h.

      3.png

      The project doesn't build I see the following error.

      2.png

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #4

      @Shadow-01 Do you have

      QT += widgets
      

      in the pro file?

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      2
      • S Shadow.01

        Hi all,
        I am totally new to QT system. In order to try the basics operations, I am trying to create a simple QT empty project with two forms and, in each form, a button to pass from a form to the other. That's all.

        1. I started by creating a new QT Quick Application - Empty
        2. I created the second form by Create new -> QT Designer form class -> Dialog with buttons

        Nothing else. And, at this point, I see the following error. Why? Have I do some mistakes?

        Thank you very much,

        Screenshot 2021-06-10 112824.png

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #2

        @Shadow-01 Please show the content of dialog.h
        Also: does the project build? The errors are probably from code model. Just try to build.

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • S Offline
          S Offline
          Shadow.01
          wrote on last edited by
          #3

          Thanks for the super fast reply!

          This is the content of dialog.h.

          3.png

          The project doesn't build I see the following error.

          2.png

          jsulmJ 1 Reply Last reply
          0
          • S Shadow.01

            Thanks for the super fast reply!

            This is the content of dialog.h.

            3.png

            The project doesn't build I see the following error.

            2.png

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #4

            @Shadow-01 Do you have

            QT += widgets
            

            in the pro file?

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            2
            • S Offline
              S Offline
              Shadow.01
              wrote on last edited by
              #5

              No, I didn't! Now I have and it's compile. You solved a part of my problem at the speed of the light! :-)

              Now I would ask you the last part, how can I put a buttom in the first form (I have only a QML file, without any .ui corresponding user interface), in order to open the second one?

              Thanks again so much for your helping!

              jsulmJ 1 Reply Last reply
              0
              • S Shadow.01

                No, I didn't! Now I have and it's compile. You solved a part of my problem at the speed of the light! :-)

                Now I would ask you the last part, how can I put a buttom in the first form (I have only a QML file, without any .ui corresponding user interface), in order to open the second one?

                Thanks again so much for your helping!

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #6

                @Shadow-01 So, you are mixing QML and Qt Widgets? Is there a reason for this? If you need to do so see https://doc.qt.io/qt-5/qtqml-cppintegration-topic.html which is somewhat advanced topic.

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                3
                • S Offline
                  S Offline
                  Shadow.01
                  wrote on last edited by Shadow.01
                  #7

                  Sorry, I have seen that I ask 2 things in the same post; I don't want to violate the rules of the forum and I put a new question. Thanks, post solved. I put the other question in a new discussion.

                  1 Reply Last reply
                  0

                  • Login

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