>I would like to know how to detect if the shift key is pressed when on a form and control. Basically, i want to change the caption of a control if the control has focus or the mouse is over the object. I am sucessfully using MouseEnter/Move/Leave and checking the nShift parameter. Also, if the the control has focus and the user presses shift, I want to change the caption.
>
>If I shift+tab, i can detect the shift keypress, but that also moves the focus to another control. I just want to detect if the keypress occurs when it has focus. The Keypress() method only seems to fire if another key is pressed as well.
Now that you got the solution, I would be interested to know what the control is showing when the Shift key is pressed?
Christian Isberner
Software Consultant