Sign in to follow this  
Followers 0
wowtop

Submit Form IE9

8 posts in this topic

Hello all,

i'm looking for help with this code :

#include <IE.au3>
 
$identifiant = "xxx"
$motdepasse = "xxx"
$oIE = _IECreate ("http://www.farmerama.com")
_IELoadWait ($oIE)
 
$oUser =_IEGetObjByName($oIE,"loginForm_default_username")
$oPass =_IEGetObjByName($oIE,"loginForm_default_password")
_IEFormElementSetValue ($oUser, $identifiant)
_IEFormElementSetValue ($oPass, $motdepasse)
 
$oValidation = _IEGetObjByName($oIE,"loginForm_default_login_submit")
_IEAction ($oValidation, "click")
 
_IELoadWait ($oIE)

It's ok to insert "$identifiant" and "$motdepasse" but i can't validate this form.

That doesn't work if i use ($i 0 to 2)

$oForm = _IEFormGetCollection ($oIE, $i)
_IEFormSubmit ($oForm, 0)

I don't want to use mouseclick.

Thanks for your help

Share this post


Link to post
Share on other sites



$forma = _IEFormGetObjByName($oIE, "loginForm_default")
_IEFormSubmit($forma)

Share this post


Link to post
Share on other sites

thanks but that doesn't work for me. That not do anything.

That seem to be logical, certainly work with another config.

I'm not sure but i have: Win7 64b & IE9.

Share this post


Link to post
Share on other sites

Related problem for IE9 fixed in latest bet builds of AutoIt. Please upgrade.

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

Share this post


Link to post
Share on other sites

Thanks DaleHohm

i update the beta version

the bug seem to come from IE.au3

i report the bug

Share this post


Link to post
Share on other sites

I'm not excited about helping you automate a game, but I tested your code with the beta and it appears to work fine.

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

Share this post


Link to post
Share on other sites

As I mentioned before, I tested your code with the beta (on WIN 7 and IE9) and encountered no errors.

You'll need to analyze your system and your code more carefully to isolate the source of the error you have receved or the bug report will simply be closed with a "Works for me" status.

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

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  
Followers 0