Jump to content

Close IE Popup window


 Share

Recommended Posts

#include <IE.au3>

$o_IE = _IECreate ()
_IENavigate ($o_IE, "http://www.whatver.com")
_IELinkClickByText ($o_IE, "Open POPUP")
_IEQuit($o_IE)

Hi hopefully someone can help me. This simple script opens a browser, clicks a link then closes the browser. My problem is that the link opens a popup window and my _IEQuit command simply closes the first browser window. How would I close the popup also ?

Thanks for any help.

Link to comment
Share on other sites

#include <IE.au3>

$o_IE = _IECreate ()
_IENavigate ($o_IE, "http://www.whatver.com")
_IELinkClickByText ($o_IE, "Open POPUP")
_IEQuit($o_IE)

Hi hopefully someone can help me. This simple script opens a browser, clicks a link then closes the browser. My problem is that the link opens a popup window and my _IEQuit command simply closes the first browser window. How would I close the popup also ?

Thanks for any help.

Try something like:

WinWaitActive("Choose a digital certificate", "")
ControlClick("Choose a digital certificate", "", "Button3")

I solved a similar issue with a pop-up to choose the digital certificate but that had an "ok" button. If you don't have an easy to access "ok" or "close" you could take a look at WinClose or WinKill and their friends...

WinWaitActive("Pop-up Title", "")
WinKill("Pop-up Title", "")

EDIT: Here is post where I found the first two lines posted above. They were part of a really cool fuction for dealing with most of the system popups especially when they show up unexpectedly: _IEPopUps()

Edited by Woongjinn
Link to comment
Share on other sites

  • 2 weeks later...

Try something like:

WinWaitActive("Choose a digital certificate", "")
ControlClick("Choose a digital certificate", "", "Button3")

I solved a similar issue with a pop-up to choose the digital certificate but that had an "ok" button. If you don't have an easy to access "ok" or "close" you could take a look at WinClose or WinKill and their friends...

WinWaitActive("Pop-up Title", "")
WinKill("Pop-up Title", "")

EDIT: Here is post where I found the first two lines posted above. They were part of a really cool fuction for dealing with most of the system popups especially when they show up unexpectedly: _IEPopUps()

Hi ,

I am facing the same issue.

i my case i have used WinWaitActive and then WinClose.but in some pop ups there are no TITLE.

WinWaitActive and WinClose required title as parameter.

can you please tell me if there are no title then how can i close that pop-up.

I have already posted topic on the this issue.

How to close any POP-UPs if there is no title??

please provide your suggestion.

Thanks,

Chetan J.

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