Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Connecting signal with multiforms

Connecting signal with multiforms

Scheduled Pinned Locked Moved Solved Mobile and Embedded
4 Posts 3 Posters 1.0k 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.
  • V Offline
    V Offline
    vivekyuvan
    wrote on last edited by
    #1

    Hi Friends I am newbie in this form .I have question in qt software development. i want to know how to connect one form to another form on pushbutton clicked with connect signal.

    Any example code and snippet will be helpful.

    jsulmJ 1 Reply Last reply
    0
    • V vivekyuvan

      Hi Friends I am newbie in this form .I have question in qt software development. i want to know how to connect one form to another form on pushbutton clicked with connect signal.

      Any example code and snippet will be helpful.

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

      @vivekyuvan I assume you execute the code bellow in one of both forms which has the button you want to connect.

      MyForm2 *form2 = new MyForm2();
      connect(this, pushButton, SIGNAL(clicked()), form2, SLOT(doSomething()));
      

      You should read http://doc.qt.io/qt-5.9/signalsandslots.html

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

      1 Reply Last reply
      2
      • P Offline
        P Offline
        patrik08
        wrote on last edited by
        #2

        Hi a perfect point to learn is ui forms..
        inside designer...
        http://doc.qt.io/qt-5/designer-connection-mode.html

        1 Reply Last reply
        0
        • V vivekyuvan

          Hi Friends I am newbie in this form .I have question in qt software development. i want to know how to connect one form to another form on pushbutton clicked with connect signal.

          Any example code and snippet will be helpful.

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

          @vivekyuvan I assume you execute the code bellow in one of both forms which has the button you want to connect.

          MyForm2 *form2 = new MyForm2();
          connect(this, pushButton, SIGNAL(clicked()), form2, SLOT(doSomething()));
          

          You should read http://doc.qt.io/qt-5.9/signalsandslots.html

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

          1 Reply Last reply
          2
          • V Offline
            V Offline
            vivekyuvan
            wrote on last edited by
            #4

            @jsulm thanks for the reply. I followed your instruction now my problem is solved.

            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