Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Ingrid Problem
Message
From
16/07/1998 15:45:18
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
15/07/1998 11:52:28
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Title:
Miscellaneous
Thread ID:
00116648
Message ID:
00118280
Views:
46
>Hi, Alex
>
>One command in the KeyPress event should be modified as follows to cover the "0" situation:
>
> CASE BETWEEN(m.nKeyCode, 48, 126) OR m.nKeyCode=32 && AlphaNumeric
>
>To increase the key reset time, change the _DBLCLICK setting (The default is 0.5 second)

I'll stop writing this, but I have a feeling everyone's forgotten it: BETWEEN(m.nKeyCode, 48, 126) doesn't cut it. Whoever wrote it first, obviously had a very narrow definition of what is an alphanumeric and what is not. This works in codepage 1252 and only in 1252. Any other codepage uses codes beyond 127 up to 254. The function IsAlpha() reflects this quite OK (i.e. it complies to the codepage defined in config.fpw) thus making your code independent of codepage.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform