I’m back here looking for some answers! I’ve been converting my scripts from maya commands UI to Pyside2 . In Maya commands there is this command “connectControl” that allows you to connect a UI element to a specific attribute.
For example one could do (code just for reference):
color = cmds.colorSliderGrp()
This would connect the colorSliderGrp UI to the color of the pSphere so that as you change the color in the UI it changes in the pSphere.
Is there a way of doing this exact same thing with PySide2? Or do we have to manually change the values every time?
I tried doing the following but an error came out:
self.first = wdg.QDoubleSpinBox()
cmds.connectControl(self.first, ‘LightRig_’ + self.CHARACTER + ‘:_face_ctrl.sx’)
RuntimeError: connectControl: Object ‘<PySide2.QtWidgets.QDoubleSpinBox object at 0x000001E4C79D7488>’ not found.