I’m developing a module to Slicer and I’m facing some issues. One of the functionalities is to place a control point and get its coordinates through a button that calls a method. I put a print on the beggining of this method and it’s called right when I start the module, but when I place de control point and click the button it gives this error: TypeError: 'NoneType' object is not callable
My guess is that self.ui.MRMLNodeComboBox_frame is the NoneType object. Make sure your UI file has this object with this exact objectName of MRMLNodeComboBox_frame and that you have saved this UI file (not unsaved changes).
I would suggest you do some continued debugging to find the NoneType object. Adding a print statement for self.ui.MRMLNodeComboBox_frame will help confirm if it is indeed an object or a NoneType.
From Description: (none) it seems to be a NoneType right? But again the method was called right when the module started, before selecting the input node and placing the control point. So I’m guessing that’s why it’s NoneType.
They are different things actually. I don’t know if that’s the most effiecient way because I’m new to Slicer but the idea is: the user place a control point trought the Markups Control Point button (PontoCentralButton), and when it’s placed they click on the “Coordenadas” button (CoordsButton), wich should call the method and get the coordinates of that control point.
Hope this helps to give more context to the problem.