Sign in to follow this  
Followers 0
pcarlow

Need Help Clicking Links

5 posts in this topic

I made my first script which opens intenet explorer, types in a search query to Google and hits return which then gives me the search results. the next thing i want to do is click on (or select) the first search result link on the page (i don't want to click on any ads). Could someone please provide some help in doing this?

Share this post


Link to post
Share on other sites



Thanks for the quick response.

I downloaded the file and renamed it IE.au3. I added: #include <IE.au3> to my script but I'm getting an error: Line 776 Unable to parse line.

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Ok, got beta working now. Here's what I have so far:

#include <IE.au3>

$o_IE = _IECreate ()
_IENavigate ($o_IE, "http://www.google.com")
WinWaitActive("Google - Microsoft Internet Explorer")
Send('test')
Send("{ENTER}")
WinWaitActive('test - Google Search')
_IEClickLinkByIndex ($o_IE, 18)

I want to be able to click on all 10 search result links on the page. The problem with the IEClickLinkByIndex function is that, i never know what the index for links 1-10 will be. Because of advertisements and other stuff it can be different every time. Any suggestions?

Edited by pcarlow

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