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. How to delete previous widget

How to delete previous widget

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 4 Posters 471 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.
  • B Offline
    B Offline
    Bharth
    wrote on last edited by
    #1

    Hi guys,,,

    Please help me to solve this issue.....
    how to delete previous widget,,,after replacing widget with another widget

    J.HilkJ 1 Reply Last reply
    0
    • B Bharth

      Hi guys,,,

      Please help me to solve this issue.....
      how to delete previous widget,,,after replacing widget with another widget

      J.HilkJ Offline
      J.HilkJ Offline
      J.Hilk
      Moderators
      wrote on last edited by J.Hilk
      #2

      @Bharth this seems somehow familiar...

      but we're going to need more information about your situation in general

      int i = myLayout->indexOf(widgetToRemove),
      QWidget *w = myLayout->takeAt(i);
      w-> deleteLater();
      

      Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


      Q: What's that?
      A: It's blue light.
      Q: What does it do?
      A: It turns blue.

      1 Reply Last reply
      0
      • B Offline
        B Offline
        Bharth
        wrote on last edited by
        #3

        @J-Hilk thank you for reply,
        i have 1 main widget where in that their will be signup and login button, when i click on signup button main widget should replace with signup widget and in the same way when i click on login button main widget should replace with login widget, but in this process main widget should delete when i replace it with signup or login widget ,and in the same way when i move to next widget previous widget should delete througout my project.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Hi,

          Is that some kind of wizard ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • annajulia1A Offline
            annajulia1A Offline
            annajulia1
            Banned
            wrote on last edited by
            #5
            This post is deleted!
            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