Sign in to follow this  
Followers 0
dnlwilson

IE windows

2 posts in this topic

I am really struggling with IE, attached is a IE window that pops up as part of a load of a vendor product we have no control of. This page is basically blank and pops open a new window that is the real web app (and I do not know how to open that window, and that window opens without an address bar etc...). So I want to create a startup that looks for this window and closes it so that when the user closes the application nothing is left and I can logout the session.

I have tried various combinations:

$oIE = _IEAttach ("http://mrmhserv1/cis/index.html")

_IEQuit ($oIE)

;

WinClose("http://mrmhserv1/cis/index.html")

are just a few, but the darn thing just sits there, I put other things in the script so that I know it has processed, and I have put in delays and messages so that I know it is not trying to close before it is open. So how can I force this specific window to close?

post-66813-0-35373200-1335387317_thumb.j

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Try this

Opt ( "WinWaitDelay", 0 )
$_WinList = WinList ( "[REGEXPCLASS:IEFrame]" )
For $_I = 1 To UBound ( $_WinList ) -1
    ConsoleWrite ( '-->-- Title : ' & $_WinList[$_I][0] & @Crlf )
    ConsoleWrite ( '+->-- Handle : ' & $_WinList[$_I][1] & @Crlf )
    If StringInStr ( $_WinList[$_I][0], 'mrmhserv1' ) Then
        WinClose ( $_WinList[$_I][1] )
        ExitLoop
    EndIf
Next
Edited by wakillon

AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

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