Jump to content

_IEFormElementGetCollection Help


 Share

Recommended Posts

Hi, I'm working with different forms on different web pages, and each form has an edit box. Now can I use _IEFormElementGetCollection to get a handle on that editbox? the problem is I can't use the index instance option for every form has a diferent index for that editbox.. So basically i need to identify the editbox handle in that form.

Thanks a lot in advance

Link to comment
Share on other sites

No, but you can loop through the objects in the collection with FOR...NEXT and examine properties like .type to find what you want.

$oElements = _IEFormElementGetCollection($oForm)
For $oElement in $oElements
    ConsoleWrite($oElement.type & @CRLF)
Next

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

  • 3 months later...

The above code is not working. Check this.

#include <IE.au3>

$oIE = _IECreate()

$navigate=_IENavigate($oie,"http://www.autoitscript.com/forum/index.php?showtopic=85387&hl=_IEFormElementGetCollection")

$oForm= _IEFormGetCollection($oIE, 0)

$oElements = _IEFormElementGetCollection($oForm)

For $oElement in $oElements

ConsoleWrite($oElement.type & @CRLF)

Next

I want to know about how to find controls present in the page after submission.

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