Hi, I’m hitting my head against something that I think is basic but I haven’t got the hang of it.
I’m using WxFormBuilder to generate a Dialog with a read_button on it, and I want to manage the OnButtonEvent.
I can generate the Dialog, and have put a print in the read_button to verify its being processed,
but I can’t figure out how to catch the overridden onMpPcReadBtn event.
Any pointers or suggestions appreciated… thanks
The wxPython calls are in gui.py.
class modifyParamDialog ( wx.Dialog ):
def __init__( self, parent ):
wx.Dialog.__init__ ( self, parent, .....
... dialog creation...
# Virtual event handlers, overide them in your derived class
def onMpPcReadBtn( self, event ):
#print('vBtn Read Product Codes')#works when enabled
event.Skip()
then in callable.py
class modifyParamActions(gui.modifyParamDialog):
def init(self,parent):
#initialize parent class
super(modifyParamActions,self).init()
print(‘init modifyParamActions’) #this doesn’t print
gui.modifyParamDialog.init(self,parent)
#provide overrides for base class
def onMpPcReadBtn(self,event):
print(‘1Btn Read Product Codes’)