I am trying to do a short simple exporting ui in which as user will select the exporting directory, then an option from the combobox (else it will only be showing Option 01 in the combobox), lastly clicking onto the Export Button
However, I am getting this error
# TypeError: exportFunc() takes exactly 3 arguments (1 given) even though I did fulfill the number of required arguments
It is working well before I modify this current code of mine
def initUI(self):
...
self.exportCombo = QComboBox()
self.exportCombo.addItem('Option 01')
self.exportCombo.addItem('Option 02')
def createConnections(self):
...
self.connect(self.exportFuncBtn, SIGNAL('clicked()'), self.exportFunc)
self.connect(self.exportCombo, SIGNAL('currentIndexChanged(const QString &)'), self.comboSel )
def exportFunc(self, minTime, maxTime):
# Function that denotes the exporting on the button
...
def comboSel(self, current):
selection = cmds.ls(sl=True)
if str(current) == 'Option 01':
minTime = cmds.playbackOptions(query=True, minTime=True)
maxTime = cmds.playbackOptions(query=True, maxTime=True)
else:
minTime = cmds.findKeyframe(selection, which='first')
maxTime = cmds.findKeyframe(selection, which='last')
self.exportFunc(minTime, maxTime)