Syntaxe Posted November 24, 2007 Share Posted November 24, 2007 (edited) I just started to learn AutoIt.And know I am tring to make a script, that opens IE, types in a url,starting PuTTY, auto puts in the choosen info.Well, my problem is that the first Send("!r") dont work as it should.Because when I come to the "Start - Save - Close" its just standing still.And yes I know that the Send($IP & "{tab}" & $PORT & "{tab}" & "{left}{left}" & "{enter}") is kinda absurd line xD - but it works Someone see the problem?; Here is our variables $IP = "ip" $PORT = "port" ; Here starts our script Run(@ComSpec & " " & "/c start IEXPLORE.EXE") WinWaitActive("Microsoft Internet Explorer") Send("{F6}") Send("http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe{enter}") WinWaitActive("File Download") Send("!r") WinWaitActive("Security Warning","") Send("!r") WinWaitActive("PuTTY Configuration") Send($IP & "{tab}" & $PORT & "{tab}" & "{left}{left}" & "{enter}") WinWaitActive($IP & " - PuTTY") MsgBox(0, "Success!") Edited November 24, 2007 by Syntaxe Link to comment Share on other sites More sharing options...
Zedna Posted November 24, 2007 Share Posted November 24, 2007 Welcome to AutoIt comunity. It's good first attempt. Here is some improvement: ; Here is our variables $IP = "ip" $PORT = "port" ; Here starts our script InetGet("http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe", "C:\putty.exe") Run("C:\putty.exe") WinWaitActive("PuTTY Configuration") Send($IP & "{tab}" & $PORT & "{tab}" & "{left 2}" & "{enter}") WinWaitActive($IP & " - PuTTY") MsgBox(0, "Success!") Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Zedna Posted November 24, 2007 Share Posted November 24, 2007 Note: Instead of Send($IP & "{tab}" & $PORT & "{tab}" & "{left 2}" & "{enter}") use better method with ControlSetText() ControlClick() Look at Au3Indo tool for get right control names. Resources UDF ResourcesEx UDF AutoIt Forum Search 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