Jump to content

IE Automation


IanN1990
 Share

Recommended Posts

Hello All, 

Its been a while since i last posted but i could never say away from autoit for long :)

I am having issue with a script.

I am using the function _IEGetObjByID shown below in a basic example

 

#include <IE.au3>

Local $oIE = _IE_create("examplewebsite.com")
Local $oSubmit= _IEGetObjById($oIE, "Go")
_IEAction($oSubmit, "click")

Now the script works perfectly. The problem is on the website i am using it has two "Go" buttons and this script only clicks the first.

How would i work around this?

Ian

P.S The website in the code is an example, as the target website is run through a intranet. So i only have access to it

Edited by IanN1990
Link to comment
Share on other sites

Unfortunately its a company website, so i cant not post anything like that i am afraid.

 

Surely this problem must be quite common though? To have two "items" with the same name?

In the help file it mentions an option for indexing using -1 instead of 0. Does this return a list of all the items found with the word Go? If so how would i access that index

Edited by IanN1990
Link to comment
Share on other sites

Following your advice though, looking at the HTML i see they are both very similar but with a few differences.

 

How could i search for a "item" by the value only

 

Example. value="Go" or perhaps Input Onclick

Edited by IanN1990
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...