Find the parent of a gadget

BlitzMax Forums/MaxGUI Module/Find the parent of a gadget

doswelk(Posted 2007) [#1]
If I have create a window and added a button to it, how do I find out what the parent is?

Or do I have to assign the window as a global?


WendellM(Posted 2007) [#2]
The GadgetGroup() function returns the parent e.g.
If GadgetGroup(button) = window Then Notify "Parent is 'window'"