Jump to content
Sign in to follow this  

Help with IE automation (using IE UDF)

Recommended Posts


The code I have below DOES work.

I need to read the "title" or "href" data from "rsTR1_0".

I've tried a lot, too many things to list here, but they are all shots in the dark. How can I do this? See screenshots below for the debugbar data I'm working with. Thanks!!!

$s_URL = http://usd/CAisd/pdmweb.exe  ;yes i know this is .exe, trust me, its a regular webpage
$o_IE = _IECreate($s_URL)
$o_Frame1 = _IEFrameGetObjByName ($o_IE, "product")
$o_Frame2 = _IEFrameGetObjByName ($o_Frame1, "sd")
$o_Frame3 = _IEFrameGetObjByName ($o_Frame2, "cai_main")
$o_Div2 = _IEGetObjByID($o_Frame3, "scrollbarDiv0")
$o_Div3 = _IEGetObjByID($o_Div2, "scrollbarDiv1")
$o_Div4 = _IEGetObjByID($o_Div3, "idResults")
$o_Div5 = _IEGetObjByID($o_Div4, "scrollbarDiv2")
$o_Form1 = _IEFormGetObjByName($o_Div5, "frmList")
$o_Table1 = _IETableGetCollection($o_Form1, "rsTbl")
$o_Result1 = _IEGetObjByID($o_Table1, "rsTR1_0")



Edited by shea851

Share this post

Link to post
Share on other sites

oTables = _IETableGetCollection ($oIE)
For $oTable in $oTables
    For $element in $oTable

This gets all the tables , and then displays the inner text of every row of every table one by one.You will be clicking OK a while :D

Your job will be to modify it a little bit.

Share this post

Link to post
Share on other sites

Without clicking "OK" for so long :-)

$oTR = _IEGetObjById($o_xx, "rsTR1_0")

$oA = _IETagnameGetCollection($oTR, "a", 0) ; get the first a tag inside

ConsoleWrite($oA.title & @CRLF)


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

Share this post

Link to post
Share on other sites

Thanks for the responses. I will test out your suggestions soon as I can, bit busy at work today!

Share this post

Link to post
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
Sign in to follow this