def run(self): """Run method that performs all the real work""" # Create the dialog (after translation) and keep reference dlg = DsgManagementToolsDialog() # show the dialog dlg.show() # Run the dialog event loop result = dlg.exec_() # See if OK was pressed if result: # Do something useful here - delete the line containing pass and # substitute with your code. pass