Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
KeyPress Event: Need for advice
Message
From
05/11/1997 05:08:22
 
 
To
04/11/1997 09:02:37
Razvan Alexandru
Soft Team Solutions Srl
Bucharest, Romania
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00058110
Message ID:
00058296
Views:
28
Hi Razvan!

>If you use KeyPreview=.T. whatever key you press and whereever you are in the form the code in ThisForm.KeyPress is executed.
>If you want to set a HotKey (a..z or 0..9) you must use NODEFAULT in KeyPress Event of the form.
>
>If you have other questions ...
>
>Razvan

Thank you for a good advice. It helps me to find a workaround of my problem.

By the way, i use KeyPreview=.T. and KeyPreview=.F. to switch the behaviour of the form. When I need some object (e.g. numeric input field) to recieve keystrokes, i use MyForm.KeyPreview=.F.
After this i found out that when i am entering in this field digits, functional keys etc., the only keypress event fired is that of the object. But when i press Enter, both object's and form keypress event occurs. Strange behavior of VFP!

That is why I should use NODEFAULT in keypress event of the form only for that keys, i need.

Thanks in advance

Alexander Mitchenko, Kiev, Ukraine
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform