frankhack1 Posted March 20, 2010 Share Posted March 20, 2010 Hi people! I am new in the forum I just got started with AutoIT. I am using Windows 7 x64 (Spanish) and Windows Live Messenger with the MSNPlus add-on so I can have multi-session msn.. If I "manually" open 3 messenger they all work well (clicking on "msnmsgr.exe" at "Program Files"), but when I try this on AutoIt, it doesn`t work This is my code: MsgBox(0, "by frankhack", "Abriendo 3 messengers!", 1) AutoItSetOption("ExpandEnvStrings", 1) Opt("WinWaitDelay", 1000) Opt("WinTitleMatchMode", 4) Opt("WinDetectHiddenText", 1) Opt("TrayIconHide", 1) ; PRIMER MESSENGER // PRIMER MESSENGER <--- Translated means FIRST MESSENGER // FIRST MESSENGER MsgBox(0, "by frankhack", "Abriendo el 1ro", 1) If Not ProcessExists("msnmsgr.exe") Then RunWait("msnmsgr.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") Else If Not WinActivate("Windows Live Messenger") Then WinActivate("Windows Live Messenger") EndIf WinWaitActive("Windows Live Messenger") Send("myaccount1@hotmail.com") Send("{TAB}") Send("mypassword") Send("!n") If ProcessExists ("msnmsgr.exe") Then ; SEGUNDO MESSENGER // SEGUNDO MESSENGER <--- Translated means SECOND MESSENGER // SECOND MESSENGER MsgBox(0, "by frankhack", "Abriendo el 2do", 1) Run("msnmsgr2.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") If Not WinActivate("Windows Live Messenger") Then WinActivate("Windows Live Messenger") WinWaitActive("Windows Live Messenger") Send("myaccount2@hotmail.com") Send("{TAB}") Send("mypassword") Send("!n") MsgBox(4, "by frankhack", "Quieres abrir la cuenta de Monica tambien?") <--- Translated means "Do you want to open Monica's account also? ; TERCERO MESSENGER // TERCERO MESSENGER <--- Translated means THIRD MESSENGER // THIRD MESSENGER MsgBox(0, "by frankhack", "Abriendo el 3ro", 1) Run("msnmsgr3.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") If Not WinActivate("Windows Live Messenger") Then WinActivate("Windows Live Messenger") WinWaitActive("Windows Live Messenger") Send("myaccount3@hotmail.com") Send("{TAB}") Send("mypassword") Send("!n") EndIf Basically I want to open 3 messenger and to login automaticly to this accounts, at least to the firsts 2 account... the third one is my girlfriend account so when she is not at home I don't need it... Link to comment Share on other sites More sharing options...
i542 Posted March 20, 2010 Share Posted March 20, 2010 (edited) Notice these: Run("msnmsgr2.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") Run("msnmsgr3.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") Changing these two lines into this might just work: Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") EDIT: *shy* wrong dir. Edited March 20, 2010 by i542 I can do signature me. Link to comment Share on other sites More sharing options...
frankhack1 Posted March 20, 2010 Author Share Posted March 20, 2010 (edited) Notice these: Run("msnmsgr2.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") Run("msnmsgr3.exe", "%ProgramFiles(x86)%\Windows Live\Messenger") Changing these two lines into this might just work: Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") EDIT: *shy* wrong dir. Hi my friend! I forgot to tell, I tried a lot of things, and the msnmsgr2.exe & msnmsgr3.exe was one of those things.. I basically copy 2 more times the msnmsgr.exe and rename it as you see them in the code... By the way, I have try your code and works just fine Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") Run(@ProgramFilesDir & "\Windows Live\Messenger\msnmsgr.exe", @ProgramFilesDir & "\Windows Live\Messenger") BUT, it opens correctly the first account, but the second account doesn't respond on time, it seems like the scripts is going to fast, because the third account is open correctly... Edited March 20, 2010 by frankhack1 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