vba - Calling AppActivate on a word 2007 window in Windows 7 gives it focus but doesn't bring it to top of stack -
I am trying to manipulate the Word from an HTA file application. Currently, when I open the word, it opens under my application. I want to open it on top I tried to use the following jscript to give focus to Word:
wshShell = new ActiveXObject ("WScript.Shell"); WshShell.AppActivate (doc.windows.Item (1) .caption);
This works, and the word gets focused, but on Windows 7 it stays below my app Do I have to do something more to bring words to the top?
If you can not force the front window, send back your own window!
Try this:
& lt; Script & gt; Window.blur (); & Lt; / Script & gt;
This will send your current window to the background.
Comments
Post a Comment