returning focus to Excel


Posted by mike faulkner on September 18, 2000 9:19 AM

I need to be able to return the focus to Excel in response to certain events in a userform.

Please look at this file if you don't know what I mean. I think it only works in Excel2000 because it contains a non-modal userform.

(broken link)

PS: I a similar question a while back and Ivan recommended they look at the application.inputbox documentation - I've been all over the help files and Microsoft site and haven't found anything.

Posted by Ivan Moala on September 18, 0100 3:11 PM


Mike, use AppActivate eg.

Private Sub CommandButton1_Click()
AppActivate "Microsoft excel"
End Sub


HTH

Ivan



Posted by mike faulkner on September 18, 0100 9:42 PM

Hey that works great! I can't thank you enough.

Mike