[Gambas-user] Accept Button on form

Tobias Boege taboege at ...626...
Sat Sep 22 13:29:56 CEST 2012


On Sat, 22 Sep 2012, Johny Provoost wrote:
> 
> Op 22-09-12 11:24, abbat schreef:
> > Hello,
> >
> > I have:
> >
> >     Form
> >         Textbox1
> >         Button1
> >
> > I need accept event.
> > After edition of textbox1 to push button1 by Enter button on keyboard.
> >
> > Can I make such an event?
> >
> > Thanks
> 
> In the 'Keypress' event from the textbox you can put
> 
> /      If Key.Code = Key.Enter Or Key.Code = Key.Return Then//
> //        Yourbutton.Value = 1//
> //      Endif/
> 
> 
> Success,
> 
> Johny Provoost

We have the TextBox_Activate() event for this purpose.

Regards,
Tobi




More information about the User mailing list