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