TypeError: __init__() takes at least 2 arguments (2 given)
Moved
Solved
Language Bindings
-
Developing a python plugin on QGIS, I get this error : TypeError: init() takes at least 2 arguments (2 given)
Here is my code :
if self.checked_list != [] : dialog = LaunchTRANUSDialog(self.checked_list,parent=self) dialog.show() result = dialog.exec_() self.reinitialise_checked_list() class LaunchTRANUSDialog(QtGui.QDialog, FORM_CLASS): def __init__(self,checked_list,parent=None): """Constructor.""" super(LaunchTRANUSDialog, self).__init__(parent) self.setupUi(self) self.checked_list = checked_list self.tabs = self.findChild(QtGui.QTabWidget, 'tabWidget')
Could you help me please ? Thank you
-
But your a init call shows only one parameter ?
-
Sorry, but I don't understand your answer . Could you explain more ?
-
Hello,
It was an other problem that causes this problem. So, I solved and now it works.
Thanks .