Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how can i use sendkeys...

Status
Not open for further replies.

yaz

Programmer
Jun 20, 2000
10
US
and write something on the last active window.

example: a command button cmd does

sendkeys("A")

but when i press the button, my word, wordpad or any textbox that was active (another program) is not anymore.

is there an api call to know what was the last active window and when i know that, how can i send text to it?
 
To reactivate a window you can use appactivate "appname"

I think this only answers part of your question, but I hope it helps.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top