Jump to content
Sign in to follow this  

How to get an index of a web page links

Recommended Posts


I need to press a specific link in a web page which have a lot of information.

i just cannot pinpoint the correct index number.

is there any tool to see the index numbers? i have tried the "Inspect element" in Chrome, it does not mention something about Index.


I really appreciate your help. (!)



Share this post

Link to post
Share on other sites

This can do the trick... IE Builder




Share this post

Link to post
Share on other sites

Hi avidovi

also, you can help yourself by adapting to your purpose a little script like this :)

#include <IE.au3>
#include <array.au3>

Local $oIE = _IECreate("http://www.autoitscript.com") ; <-- put here your link

Local $oLinks = _IELinkGetCollection($oIE)
Global $Links[@extended][3]

$Index = 0
For $oLink In $oLinks
    $Links[$Index][0] = $Index
    $Links[$Index][1] = $oLink.id
    $Links[$Index][2] = _IEPropertyGet($oLink, "innerhtml")
    $Index += 1

P.S. (off topic further info)
in Firefox browser, if you Rightclick on an element of the page and select "analyze element" you get a lot of info,
also, when the page of the developer tools is displayed with the element info, if you click on a little icon with a cube located on the upper right side of the tools area, you will see an amazing  :o  view of the page web in 3D (can also be rotated) with all the elements layered

Edited by PincoPanco

small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....

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