Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Keypress event
Message
De
15/02/2012 12:28:55
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Keypress event
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Divers
Thread ID:
01535480
Message ID:
01535480
Vues:
95
I have a textbox control with an Inputmask set to "!!!!!!!!!!"

the code in the Keypress event is
LPARAMETERS nKeyCode, nShiftAltCtrl

IF NOT INLIST(nKeyCode, 9, 13, 15)
	DODEFAULT()
	thisform.setFilter 
	NODEFAULT
ENDIF	
When I press a key the value in the textbox shows as lower case and is treated as lower case in the setFilter method. When the control loses focus, the value in the control becomes upper case.

Is there anything I can do to have the value immediately displayed as Upper Case?

I tried putting
this.value = UPPER(this.value)
this.selstart = LEN(TRIM(this.value))
immediately after DODEFAULT()

and that seems to work. But I'm curious if there is simply some property that I can set or a better way to get the value immediately in upper case.

Thanks to all...............Rich
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform