Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Eliminate nKeyCode from KeyPress Event
Message
De
25/11/1997 08:36:08
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00062104
Message ID:
00062121
Vues:
18
>>I am working in a data entry screen. My users dont't like to use mouse, so i have a menu like a label
>>and i execute data entry forms with the key press event (if nkeycode=13).
>>All my forms are based on a class. The problem is that always the focus is on the second TextBox
>>(because of chr(13)). As the code for the KeyPres Event is on the class, i don't know the name of
>>the first control to set the focus.
>>I tried KEYBOARD CLEAR, CLEAR TYPEAHEAD i cannot solve the problem.
>>Is there any easy way to overcome this problem (ex. in VB nKeyCode=0)?
>Fotis,
>
>You need to add a NODEFAULT command when you process the keystroke. This stops VFP's default processing of the keystroke. The code would look something like this in the keypress event;
>
> IF nKeyCode = 13
> NODEFAULT
> * Do your stuff here
> ENDIF


Thank you very much, this was the solution of my problem
Fotis
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform