Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Stupid question
Message
De
09/04/2008 10:03:13
 
 
À
09/04/2008 09:56:14
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01309268
Message ID:
01309301
Vues:
13
>>>My *guess* is so that the characters actually entered by the user can be idntified. Spaces entered and the like.
>>>
>>
>>I kind of sort of see what you are saying but not quite. That is, on the surface of it, the KEYPRESS method can "get" the value entered in the textbox (space of otherwise) and Seek on it.
>>
>>>Does it strip out the 255s before it SEEKs?
>>>
>>
>>The Chr(255) is "stripped out" by VFP itself. That is, when the stuffed Chr(255) fires KEYPRESS method, the KEYPRESS method processes the value in the text box (seeking on it) and it gets rid of the Chr(255).
>>
>>Thank you.
>
>Even though you can "get" the value entered, it's much easier to replace the starting chr(255)'s with the value. I know, because I used a similar solution myself in "The good old days". Especially backspace gave problems with the seemingly easy problem. Also the CHR(255) solution made it much easier to see any trailing spaces entered by the user.

Imho, using InteractiveChange event instead of KeyPress would eliminate all issues.
Edward Pikman
Independent Consultant
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform