Hi,all, I am a new user to wxpython. I have just ran into a problem
recently that I have a separate clicklistbox frame window that would
pop up upon clicking on a button on the main frame and by checking the
items on the checklist I want to append them into a list defined in
the main frame, but I just can't get it to work since there should be
something wrong with the way I call the onbutton function. anyone can
help me out? thanks!
here is the piece of the code:
inside the mainframe:
def OnShowButton(self,event):
showallframe = ShowAll(self.list) # ShowAll is the customized
frame embedding a checklist box
showallframe.Show()
to_extend= showallframe.returnlists() # returnlist is the method
of ShowAll class, which simply returns a list of the checked terms
if len(to_extend):
self.orginalist.extend(to_extend) # extend the original list in
the main frame of the program
the problem is that it is always giving an empty to_extend, I don't
know how to make the returnlist() method return the list only after I
check the items and hit on the add button on the small popped out
window.
Thanks!
winter