jgshier Posted March 16, 2004 Share Posted March 16, 2004 I am running Outlook 2003. I am try to run a script to close a vpn connection after outlook closes., but can't get autoit to see outlook. WinWaitClose("Inbox - Microsoft Outlook") do something... I used windows spy to make sure it was the right window. Seems to work fine with Notepad... Even WinWaitActive("Inbox - Microsoft Outlook") does not work. Thanks Link to comment Share on other sites More sharing options...
scriptkitty Posted March 16, 2004 Share Posted March 16, 2004 (edited) Outlook and OutlookExpress have some wierd windows. like HiddenWindow and FolderSync Window Class. You can close them and really not notice any difference, at least I can't figure out what they do atm. I usually use the text part with outlook scripts, ex: AutoItSetOption("WinTitleMatchMode", 2);2 = Match any substring in the title winactivate("Outlook","Folder") or I just: AutoItSetOption("WinTitleMatchMode", 2) winclose("HiddenWindow") winclose("FolderSync") ;... rest of script edit.. WinXP and WinME have different hidden windows. and oh yea, I found it like this: AutoItSetOption("WinTitleMatchMode", 2) $title = WinGetTitle("Outlook", "") MsgBox(0, "Full title read was:", $title) Edited March 16, 2004 by scriptkitty AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
nobby Posted March 17, 2004 Share Posted March 17, 2004 Hey, Instead of getting the window title, why not use the ProcessExists function? If ProcessExists("Outlook.exe") then rest of script Cheers CheersNobby Link to comment Share on other sites More sharing options...
scriptkitty Posted March 17, 2004 Share Posted March 17, 2004 oops, funny how I didn't read the first part of the question, yea process would be better, like maybe: ProcessWaitClose ( "Outlook.exe" ); optional [, timeout] AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now