I am having a function in which it executes another dialog with its class name. In that dialog there is a cancel button. I need to do is, when the cancel button is clicked it should come out of the entire thing. How to do this??
I am having a function in which it executes another dialog with its class name. In that dialog there is a cancel button. I need to do is, when the cancel button is clicked it should come out of the entire thing. How to do this??
connect the "clicked()"-signal of the button with the "close()"-slot of your dialog
I am executing the dialog from other dialog class using its object. How to connect with the clicked() signal??
sorry, were going back to your old problem. please, describe more precisely, what you want.
you have dialog A and dialog B. which dialog has the close()-button? which dialog do you want to close when the button is clicked?
If you want a button/tool button/menu to attempt to quit the entire program connect its clicked() or triggered() signal to the QApplication::quit() slot. It doesn't matter if the button is on a dialog (or which dialog), a tool bar or menu.
To anticipate your next question: you access the application object through the global qApp pointer.
Bookmarks