I have several ListBox controls on a ContainerControl. I am attempting to use the ContainerControl’s MouseDown event to select the first row in whatever ListBox I click in. Is this even possible? Or do I need to use the MouseDown event for each Listbox instead of the ContainerControl’s?
Here is the code I have in the ContainerControl’s MouseDown event but it isn’t working:
[code] for i as integer = 0 to self.ControlCount-1
if self.Control(i) isa MyListbox then MyListbox(Control(i)).Selected(0) = True end if