Jump to content

Recommended Posts

Posted

if multiple buttons have the same form, how do i submit or click the buttons? cause ieformsubmit would only submit the last button used, i need it to click the specific buttons when its told to do so...what code would i use for this?

Posted

if multiple buttons have the same form, how do i submit or click the buttons? cause ieformsubmit would only submit the last button used, i need it to click the specific buttons when its told to do so...what code would i use for this?

$oButton = _IEFormElementGetObjByName($oFrom, "buttonName") then _IEAction($oButton, "click")

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

Posted

Huh, this method not working for me (on the target page is many buttons). When I click manually on the button for download file, this work. But with code below show IE security warning msg (activeX) on top screen and download not working.

<form method="GET" action="default.php">
<input type="hidden" name="imgs" value="collected" />
<input type="hidden" name="actions" value="generate" />
..
..
..
    <dd class="cust_text"><input type="text" class="inputbox" name="iak,fi,13" value="Default_name_BLACK">
    <dd class="rows_buttons"><input type="submit" name="sak,fi,13" value="Download"></dd>
..
    <dd class="cust_text"><input type="text" class="inputbox" name="ial,fi,13" value="Default_name_GREEN">
    <dd class="rows_buttons"><input type="submit" name="sal,fi,13" value="Download"></dd>
..
    <dd class="cust_text"><input type="text" class="inputbox" name="iam,fi,13" value="Default_name_BLUE">
    <dd class="rows_buttons"><input type="submit" name="sam,fi,13" value="Download"></dd>
..
..
..

My code (form is without name and '1' is correct):

$oForm = _IEFormGetCollection($oIE, 1)   
$myButton = _IEFormElementGetObjByName ($oForm, "sak,fi,13")
_IEAction ($myButton, "click")
_IELoadWait ($oIE)

_IEAction ($myButton, "focus") > but this is work correctly and button have focus.

Any idea?

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
×
×
  • Create New...