John K ha scritto:
> Re my earlier e-mail I've solved the problem by repopulating the 
> combobox at the end of the Button_Click() subroutine.
> However I have another question. If I create a combobox with:
> DIM hComboBox AS ComboBox
> hComboBox = NEW ComboBox ( Frame1 )
>
> it doesn't accept any events ie hComboBox_Change()
>   
You should instanciate it with:

   hComboBox = NEW ComboBox(Frame1) as "mycmbbox"

(note the "as xxxxx"). Then declare:

   public sub mycmbbox_change()
   .....

The toolbox works because it does automatically something similar. Ask 
Benoit, he knows better than me: the interpreter does know nothing about 
variable names, so if you rely on variable names to manage events, you fail.

Regards.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to