Passing focus to another application

F

Fred

If shell out to another application how can I pass the focus to that
application.
When I run:

Shell "notepad.exe C:\Temp\MyFile.txt"

it starts notepad OK but the focus remains with excel. I want the focus to
goto notepad.

Thanks for any help
Fred
 
R

rdidentity

hey

Shell "c:\windows\notepad.exe", 1

will activate your window
here is another states
0 - hide
1 - normal
2 - minimized
3 - maximized
4 - normal size but not focused
5 - minimized and not focused

i hope i have answered your question
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top