Jump to content

IE Automate Scripts


redih
 Share

Recommended Posts

I'll ask my question first; then give you reasons to answer it:

Are there any scripts that I can work off of to automate repetitive log-ins / adding information through Internet Explorer?

I own an insurance agency and it takes forever to quote insurance through multiple companies. I would like to automate the process with a macro type script. We currently use MacroExpress, but if the internet slows down the macro messes up. So I need a wait function for IE to catch up. Or if we are quoting different coverages; Macro Express cannot recognize and change to different coverages.

If I had an example macro IE script to work off; I could edit it myself to suit my needs.

Why you should help me

I'll make a decent donation to AutoIt if I can get it to work

I will help further along the community by recommending to other agencies

They will donate to AutoIt

I will do most of the work, I just need some direction

By the way, I accidently posted this in the GUI forum. Please do not think I am double posting.

Link to comment
Share on other sites

hmm have u tried searching the forums for ie automation or w/e u are looking for or even better the help file go through the helpfiel looking for ie automation

all don8ions are welcome XD :)

dw bout the gui forum im sure the mods will jsut delete it

cheers C.W

C.Wnew rules:1.dont use plz in a post or title use please instead2.always use help file as it is now muchly over rated3. dont think where not watching u4.please wait 24 hours after last post ot bump XD i use to make that mistake

Link to comment
Share on other sites

Here is my script so far:

#include <IE.au3>
 
; Create a browser window and navigate to hotmail
$oIE = _IECreate ("https://safesite.safeco.com/dpec/signin.asp?OriginalURL=/safeconow/default.aspx")
 
; Get pointers to the login form and username, password, and signin fields
$o_form = _IEFormGetObjByName ($oIE, "frmsignin")
$o_login = _IEFormElementGetObjByName ($o_form, "txtUserID")
$o_password = _IEFormElementGetObjByName ($o_form, "txtPassword")
$o_signin = _IEFormElementGetObjByName ($o_form, "btnLogin")
 
$username = "XXXXXXX"
$password = "XXXXX"
 
; Set field values and submit the form
_IEFormElementSetValue ($o_login, $username)
_IEFormElementSetValue ($o_password, $password)
_IEAction ($o_signin, "click")

_IELoadWait($oIE)
_IELinkClickByText($oIE, "Personal")
_IELoadWait($oIE)
_IELinkClickByText($oIE, "Quote & Issue New Business")
WinWaitActive("Quote and Issue New Business")


Exit
Link to comment
Share on other sites

  • 3 weeks later...

Figured out how to click the links. Now it opened a new browser, I have to figure out how to focus on the new browser.

See _IEAttach

Dale

Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y

Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

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...