Jump to content
Sign in to follow this  

Confirmation Pop-up

Recommended Posts


Hello everyone, this is my first post on the forums so I hope I am posting in the right place and not doing anything wrong ;)

I've been trying to get used to the _IE commands to do things more 'properly' than before when I was using my default browser (firefox) and lots of mouse click and sends. It was all going fine but just now I've hit a problem:

There is a picture I would like to click on, and the picture is a link to another webpage. When you click on the picture the website gives you a little "are you sure you wish to navigate away from this page" type message with an 'ok' and a 'cancel' button.

Before, when I was using firefox, I was clicking on this picture and then using Send("{ENTER}") to immediately press the ok button. But now when I try to do the same thing in IE the box doesn't go away. I've tried sleep commands before pressing enter, and using control send to the pop-up. I even tried telling it to mouse click on the 'ok' button, but it's as if the script is waiting until I manually deal with the message box before it will even continue the script.

Perhaps I am just missing something so I hope someone can help. My code is below if it might help show where I am going wrong:

#include <IE.au3>
$oIE = _IECreate("about:blank")
_IENavigate($oIE, "$url")
_IEImgClick($oIE, "$imgtext", "alt", 0, 0)

Thank you in advance anyone who can help :)

Share this post

Link to post
Share on other sites

You will get most help on this forum if you can provide a reproducer script. That means a script that is as small as possible to reproduce the problem and contains all necessary information.

At the moment the URL you want to work with is missing.

My UDFs and Tutorials:


Active Directory (NEW 2017-04-18 - Version - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (NEW 2017-02-27 - Version - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2015-04-01 - Version - Download - General Help & Support - Example Scripts
Excel - Example Scripts - Wiki
Word - Wiki
PowerPoint (2015-06-06 - Version - Download - General Help & Support

ADO - Wiki


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  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.