Jump to content

Recommended Posts

I get a message box from the OS that has an OK button. Autoit spy shows the following:

>>>>>>>>>>>>( Window Title )<<<<<<<<<<<<<

Network Connections

( classname=#32770 )

>>>>>>>>>>>( Mouse Position )<<<<<<<<<<<<

On Desktop: x: 507 y: 162

In Window: x: 404 y: -149

>>>>>>>>>>>>>( Pixel Color Under Mouse)<<<<<<<<<<<<<

Dec: 13554646 Hex: 0xCED3D6

>>>>>>>>>>>( Window Position )<<<<<<<<<<<

left: 103 top: 311 width: 477 height: 119

>>>>>>>>( Last Control Under Mouse )<<<<<<<

>>>>>>>>>( Status Bar Text )<<<<<<<<

>>>>>>>>>>>( Visible Window Text )<<<<<<<<<


An entry named Wireless VPN Connection already exists. Choose a different name.

>>>>>>>>>>( Hidden Window Text )<<<<<<<<<

I want the script to end if the Visible Window text matches. But how do I handle the OK button?

Link to post
Share on other sites
  • Developers

So how does the command go to use the isvisible, click ok to cancel that window, then cancel on the whole setup of a new vpn connection


what does Au3_Spy tell you when you hover over the OK button ?

If it gives a control name you probably can use ControlClick()...

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
Live for the present,
Dream of the future,
Learn from the past.

Link to post
Share on other sites

I should have put my script here to begin with to be more clear:




WinWaitActive ( "Run", "" , 100 )


WinWaitActive ( "Network Connections", "" , 100 )


WinWaitActive ( "New Connection Wizard", "" , 100 )











ClipPut("Wireless VPN Connection")



ControlClick("Network Connections", "", "", "center")


;MsgBox ( 0, "Wireless VPN Installation", "This install was successful" , 2 )

Problem is if you already have the script it will fail.

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
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...