Sign in to follow this  
Followers 0
krembo404

_IEAction($o_button, "click") issue?

23 posts in this topic

Hi all,

The following code will work with autoIt 3.3.10.2 but not with 3.3.6.1:

#include <ie.au3>

$IEInstance = _IECreate("https://manage.windowsazure.com")

_IELoadWait($IEInstance, 500, 10000)

Dim $o_login = _IEGetObjById($IEInstance, "cred_userid_inputtext")

Dim $o_contButton = _IEGetObjById($IEInstance, "cred_continue_button")

_IEFormElementSetValue($o_login, "<some_user_name>")

_IEAction($o_contButton, "click")

I am using IE11. I also tried to call directly to the DOM interface by calling $o_contButton.Click() but it did not work.

Any thoughts about this? Thank you very much!

Share this post


Link to post
Share on other sites



Hi JohnOne, thanks for the answer.

It also doesn't work with IE9 (I tried). Any other ideas? Should I go as early as IE8? IE7? Also, what is UDF?

Thanks again.

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

All the _IE*** functions you are using come from the IE UDF (User Defined Functions) of IE.au3.

I'm not sure what you mean by "Should I go as early as IE8? IE7?" just use latest AutoIt release.

Edited by JohnOne

AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt

Monkey's are, like, natures humans.

Share this post


Link to post
Share on other sites

Thanks.

Thing is I have to work with 3.3.6.1 because of other dependencies. Any hope to still use this version?

Share this post


Link to post
Share on other sites

3.3.6.1 was release 4 years ago, which is pretty old. Can you further explain what dependencies are preventing you from upgrading?

Also, are there any errors showing in the Output window when you run your script in Scite?

Share this post


Link to post
Share on other sites

You might want to see if this trac ticket #1975 might be related to your issue.


If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Share this post


Link to post
Share on other sites

Universalist - no errors. It just quits with code 0.

BrewManNH - I tried but it didn't work :( Toda.

Share this post


Link to post
Share on other sites

#10 ·  Posted

Run your script in Scite and post the results from the Output window.

Share this post


Link to post
Share on other sites

#11 ·  Posted

>"C:Program Files (x86)AutoIt3SciTE..autoit3.exe" /ErrorStdOut "C:devAutoit SandboxtestAzure6.6.3.1.au3"

>Exit code: 0     Time: 7.809

Share this post


Link to post
Share on other sites

#12 ·  Posted

3.3.6.1 was release 4 years ago, which is pretty old. Can you further explain what dependencies are preventing you from upgrading?

 

Can you answer this?

Share this post


Link to post
Share on other sites

#13 ·  Posted (edited)

Can you answer this?

Yes. Well, other components are written on top of autoit and they are tested with 3.3.6.1. Therefore to upgrade, I need to run regression tests on all other components, which can be cumbersome.

Edited by krembo404

Share this post


Link to post
Share on other sites

#14 ·  Posted

Any other ideas?

Share this post


Link to post
Share on other sites

#15 ·  Posted

When your script runs, the field gets populated but the button click isn't registering, correct? If so, does it work if you manually click the button at this point?

Share this post


Link to post
Share on other sites

#16 ·  Posted

When your script runs, the field gets populated but the button click isn't registering, correct? If so, does it work if you manually click the button at this point?

Yes. Works with no problem.

Share this post


Link to post
Share on other sites

#17 ·  Posted

Not sure what else it could be. Have you made a call to _IEErrorHandlerRegister to enable to COM error handler?

Share this post


Link to post
Share on other sites

#18 ·  Posted (edited)

i just tryed with 3.3.6.1 on XP ie 8, no problem clicking button with your script.

you did not check did _IEGetObjById return any errors!

 
pls paste full console output results from this script of testing (i want to see your environment info) this script on your environment and tellme did it fail thistime or not.

#include <ie.au3>
$IEInstance = _IECreate("https://manage.windowsazure.com")
_IELoadWait($IEInstance, 500, 10000)
Dim $o_login = _IEGetObjById($IEInstance, "cred_userid_inputtext")
_IEFormElementSetValue($o_login, "<some_user_name>")

Dim $o_contButton = _IEGetObjById($IEInstance, "cred_continue_button")
If @error Then ConsoleWrite("!> you have _IEGetObjById error:" & @error & @CRLF)

$IEInstance.document.parentwindow.execScript('javascript:EmailDiscovery.ValidateUserInput()', "javascript")
Edited by bogQ

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 

Share this post


Link to post
Share on other sites

 

i just tryed with 3.3.6.1 on XP ie 8, no problem clicking button with your script.

you did not check did _IEGetObjById return any errors!

 

pls paste full console output results from this script of testing (i want to see your environment info) this script on your environment and tellme did it fail thistime or not.

#include <ie.au3>
$IEInstance = _IECreate("https://manage.windowsazure.com")
_IELoadWait($IEInstance, 500, 10000)
Dim $o_login = _IEGetObjById($IEInstance, "cred_userid_inputtext")
_IEFormElementSetValue($o_login, "<some_user_name>")

Dim $o_contButton = _IEGetObjById($IEInstance, "cred_continue_button")
If @error Then ConsoleWrite("!> you have _IEGetObjById error:" & @error & @CRLF)

$IEInstance.document.parentwindow.execScript('javascript:EmailDiscovery.ValidateUserInput()', "javascript")

 

Hi,

It didn't work either :( I am running on Windows Server 2008R2.

The output of the script is nothing special:

>"C:Program Files (x86)AutoIt3SciTE..autoit3.exe" /ErrorStdOut "C:devAutoit Sandboxtest.au3"

>Exit code: 0      Time: 5.771

Share this post


Link to post
Share on other sites

#20 ·  Posted (edited)

Server OS should have enhanced security aldo i don't know if this is the case coz I cant test under your environment so i really aren't eligible to help in this case.

 

Thanks.

Thing is I have to work with 3.3.6.1 because of other dependencies. Any hope to still use this version?

 

What dependencies are you talking about?

How about that you test under 3.3.8.1 and upgrading if its working ok for you? Dont think upgrade from 3.3.6.1 to .3.3.8.1 will have alot of script braking changes.

And what is "Autoit Sandbox" from your scite log, just a stragne folder name or it is realy some kinde of program sandbox limiting autoit to run in it?

Edited by bogQ

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 

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