This will keep a form from losing focus, for example an options box or something.
VB Code:
Private Sub Form_Deactivate() Me.SetFocus End Sub
Form_LostFocus only works if the form has no controls on it, so this is the much better way to do it. I don't know how to make it flash like a MsgBox does when you try to take away its focus, but this gets the job done.




Reply With Quote