>>Hi all,
>>
>>I like to implement a function to the ALT-P key to activate the PROPER() function on the current active TextBox on the form.
>>
>>I already tried:
>>
>>ON KEY LABEL ALT+P MyProper(ThisForm.Activecontrol.Value)
>>
>>FUNCTION(tcValue)
>>
>>Proper(tcValue)
>>
>>RETURN(.T.)
>>
>>It dit not work because the 'ThisForm.' does only works on the form itselve.
>>
>>Wat is an other way to make this work ??
>>
>>Thanks in advance,
>>
>>Theo
>
>Try the following code in the KeyPress() of the testbox
>
>****************
>LPARAMETERS nKeyCode, nShiftAltCtrl
>IF nKeyCode = 25 && ALT-P
> This.Value = PROPER(This.Value)
> NODEFAULT
>ENDIF
>****************
>
>HTH
Richard,
I think Alt+Letter would bypass keypress.
Cetin