Jump to content

_IEPropertyGet help needed


Recommended Posts

#include <IE.au3>

Opt("WinWaitDelay", 100)
Opt("WinTitleMatchMode", 4)
Opt("WinDetectHiddenText", 1)
Opt("MouseCoordMode", 0)

WinWait("Microsoft Excel", "")
If Not WinActive("Microsoft Excel", "") Then _
        WinActivate("Microsoft Excel", "")
WinWaitActive("Microsoft Excel", "")
Send("{CTRLDOWN}c{CTRLUP}")

$sURL = ClipGet()
$oIE = _IECreate($sURL, 0, 1, 0)
$hwnd = _IEPropertyGet($oIE, "hwnd")
Sleep(2000)
WinSetState($hwnd, "", @SW_MAXIMIZE)
WinActivate($hwnd, "")
_IELoadWait($oIE)
Sleep(2000)

If _IEPropertyGet ($oIE, "locationurl") = http://www.abc.com/verify? Then
    WinClose ($hwnd, "" )
    Else

_IELinkClickByText($oIE, "Download")

I want the portion of

If _IEPropertyGet ($oIE, "locationurl") = http://www.abc.com/verify? Then

WinClose ($hwnd, "" )

Else

_IELinkClickByText($oIE, "Download")

If it contains that part of the URL - there are additional text behind http://www.abc.com/verify?ajsdiofha

so if it contains http://www.abc.com/verify? I want it to close the window or else it will just move on to the next part of the script.

How can I do that?

Link to comment
Share on other sites

You want search inside string if is some other string inside it?

Use StringInStr command to search is some word/address inside it.

Happy programming!

i542

I can do signature me.

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