Jump to content

HTML Format?


 Share

Recommended Posts

The section below is suppose to go to a website and grab/visit url links. But I don't get what format the links should be in, the original coder made it 2-3 years ago and said he forgot so he couldn't give me any support...

Its just a blank page by the way, hope someone could help me in figuring this out :graduated:

#Region Link functions
 
Func _IELinkClickByText(ByRef $O_OBJECT, $S_LINKTEXT, $I_INDEX = 0, $F_WAIT = 1)
    If Not IsObj($O_OBJECT) Then
        __IEERRORNOTIFY("Error", "_IELinkClickByText", "$_IEStatus_InvalidDataType")
        SetError($_IESTATUS_INVALIDDATATYPE, 1)
        Return 0
    EndIf
    Local $FOUND = 0, $LINK, $LINKTEXT, $LINKS = $O_OBJECT.document.links
    $I_INDEX = Number($I_INDEX)
    For $LINK In $LINKS
        $LINKTEXT = $LINK.outerText & ""
        If $LINKTEXT = $S_LINKTEXT Then
            If ($FOUND = $I_INDEX) Then
                $LINK.click
                If $F_WAIT Then
                    _IELoadWait($O_OBJECT)
                    SetError(@error)
                    Return -1
                EndIf
                SetError($_IESTATUS_SUCCESS)
                Return -1
            EndIf
            $FOUND = $FOUND + 1
        EndIf
    Next
    __IEERRORNOTIFY("Warning", "_IELinkClickByText", "$_IEStatus_NoMatch")
    SetError($_IESTATUS_NOMATCH)
    Return 0
EndFunc

Thank you

Edited by Ranger08
Link to comment
Share on other sites

That is a function which is part of the standard IE.au3 UDFs that come along with Autoit3 installation.

IE functions are still very much supported here by Dale Hohm, the author of the above function.

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

Monkey's are, like, natures humans.

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...