Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Intercepting keystrokes
Message
From
09/06/1998 23:27:12
David Moreau
Iglesia Ni Cristo - Dnm
Quezon, Philippines
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00105416
Message ID:
00106572
Views:
72
David,
You responded:
>Using DoDefault() and/or an explicit TextBox::KeyPress() call without a NODEFAULT will cause the doubled characters. If you are losing the function of some keys it can only be due to a NODEFAULT issued when it shouldn't be. You also need to make sure you are properly calling the other inherited code from the ParentClass.
>

Here is my real life example. I have a container which contains a textbox. This textbox is derived directly from the VFP5 class.

The Keypress function contains the following:

LPARAMETERS pKey, pSCA

NODEFAULT && to avoid double keystrokes

DO CASE
CASE pkey = 5 AND pSCA = 0 && down arrow
&& do some stuff - this works correctly
CASE pkey = 24 AND pSCA = 0 && up arrow
&& do some stuff - this also works correctly
OTHERWISE
dodefault(pkey, pSCA) && this does not handle the TAB :-(
ENDCASE


What is wrong with this? Why do TABs and Shift-TABs no longer move the focus to the next and previous controls respectively?

This is a different class from the one that originally gave me this problem.

Thanks in advance.
David Moreau
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform