Are you returning false from Valid method of the previous control? Or do you have some code in its LostFocus preventing it from losing the focus?
>I did what you said and the messagebox never came up upon clicking on the CANCEL button. This is why I am so puzzled; it doesn't seem to be anything obvious. You can tell that I am clicking on it, yet nothing happens. In fact, the cursor seems to jump up to the first object on the form and that's where it sits. I think I need some good VFP old guy counseling.
>
>
>MESSAGEBOX("I am Clicked!", 0, "Clicked")
>SET STEP ON
>WITH ThisForm
> .lEditing = .F.
> .Revert()
> .saveButton.Enabled = .F.
> .IsDeleted()
> .Disable_Page1()
> .lblModeStatus.Caption = "VIEW MODE"
> .Show_Specs()
> .CountRecs()
>ENDWITH
>This.Enabled = .F.
>WITH ThisForm.cpageframe1
> IF .activepage=1
> .cPage1.newButton.Enabled = .T.
> .cPage1.grdCerts.SetFocus()
> ELSE
> .cPage2.ws1TextBox.SetFocus()
> ENDIF
>ENDWITH
>
If it's not broken, fix it until it is.
My Blog