Hi

I use this:


> '---------------------------------------------------------
> PUBLIC SUB txtBarcode_KeyPress()
>   IF InStr("1234567890", key.text) = 0 THEN 
>     STOP EVENT 
>   ENDIF 
> END
> '---------------------------------------------------------
> PUBLIC SUB txtBarcode_KeyRelease()
>   SELECT CASE key.Code
>     CASE key.Enter, key.return
>       evalBarcode 'function below
>     CASE key.Left
>       txtPlus.SetFocus
>     CASE key.Delete
>       txtBarcode.text = ""
>     CASE key.BackSpace
>         txtBarcode.text = ""  
>   END SELECT 
> END
> '---------------------------------------------------------
> 

I'm not sure I can explain why the keypress event doesn't kil the <enter>
but it doesn't. Works all day every day.

rgds
-- 
View this message in context: 
http://old.nabble.com/Text-box-event-triggered-by-%3Center%3E-tp27725597p27726295.html
Sent from the gambas-user mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to