Calling dialog window from main window
Unsolved
Qt for Python
-
I used Qt5 Designer to create a MainWindow object. One of the menu items calls a dialog window, so I created another (dialog) window in Qt5 Designer, which had to be saved to a separate .ui file. I could not find in Qt5 Designer how to set up an action invoking this dialog window from the main window, so I'm trying to code this by hand. Then I used pyuic5 to convert the Designer code to Python code. Both Python files have two methods:
setupUi and retranslateUi . Here's how I'm trying to invoke this dialog in the file containing the MainWindow :self.actionE_mail.triggered.connect() -or- self.actionE_mail.triggered.connect(addemail.Ui_addEmail.retranslateUi)
But I'm getting the following error:
python3 main.py TypeError: retranslateUi() missing 1 required positional argument: 'addEmail' Abort trap: 6
Can someone please help me with this? Also, I would appreciate if someone could tell if there is a way in Qt Designer to set up events like this.