Jump to content

Newbie: Tweaking Help


Guest woodman40
 Share

Recommended Posts

Guest woodman40

This is my first AutoIt script and my first forum post here. The script will reside on library public access computers and will initiate an Encarta session. This works but it is a little slow and has a couple of points where patrons with bad impulse control can intervene.

I know I can tweak the Sleep settings but is there a more elegant way to do this with hidden execution and a little more speed?

Run("C:\Program Files\Internet Explorer\IEXPLORE.EXE ")

Sleep(5000)

ClipPut ("http://login.passport.com/login.srf?lc=1033&id=30352&ru=http%3a%2f%2fencarta.msn.com%2fencnet%2fsignin%2fsigninmain.aspx%3fsc%3d1%26cred%3d7%26tgt%3dhttp%253a%252f%252fencarta.msn.com%252fDefault.aspx&tw=14400&kv=5&ct=1105659257&ems=1&ver=2.1.6000.1&tpf=23b6172d317b0161ef082733a818109d")

Send("!d")

Sleep(200)

Send("^v")

Send("{ENTER}")

Sleep(4000)

ClipPut ( "ALoginName" )

Send("^v")

Send("{tab}")

ClipPut ( "APassword" )

Send("^v")

Send("{enter}")

Link to comment
Share on other sites

I don't have time to comment this code, but it might work... You can try using the BlockInput once you are sure the code works. Make sure there aren't any popup windows that might interefere such as Windows XP SP2 feature about a popup window being blocked.

Opt("SendKeyDelay", 1);speed things up a bit

;;;;BlockInput(1)
$IE = @ProgramFilesDir & "\Internet Explorer\iexplore.exe"
$url = "http://login.passport.com/login.srf?lc=1033&id=30352&ru=http%3a%2f%2fencarta.msn.com%2fencnet%2fsignin%2fsigninmain.aspx%3fsc%3d1%26cred%3d7%26tgt%3dhttp%253a%252f%252fencarta.msn.com%252fDefault.aspx&tw=14400&kv=5&ct=1105659257&ems=1&ver=2.1.6000.1&tpf=23b6172d317b0161ef082733a818109d"

Run($IE & " " & $url)
WinWaitActive("Please sign in - Microsoft Internet Explorer")
sleep(2000)
Send("Username")
Send("{TAB}")
Send("Password")
Send("{ENTER}")
;;;;BlockInput(0)
Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...