>I have a Textbox control. When I exit that control I compare the original value with the current value. If they are the same, then I don't do anything. I now want to run the validation/lost focus code if they exit by pressing the ENTER key. If the user TABs out or mouse-clicks out, I want to follow the original logic.
>
>How can I capture the keystroke/mouse action the caused the exit from the control?
Try
IF LASTKEY() = 13 AND NOT MDOWN()
...
--sb--