Jump to content

Recommended Posts

Posted (edited)

OK, I'm trying to create a script exit via opening the Windows start menu (vista) and matching the white in the info box there.

Basically...have the script running, running, running, hit the windows key, start menu opens, white background of the recently used programs list is shown, script stops. (got stuck in a few infinite loops earlier where I had no control over the mouse to manually close the script)

I made a little test script to work on this, but for the life of me, I can not get this to work. Anyone see anything blaring'ly wrong?

  Quote

$i = 1

Do

if PixelGetColor(252,980) = "FFFFFF" Then

Send ("o")

Sleep(300)

EndIf

Send ("x")

Sleep(200)

Until $i = 2

I usually just test this with notepad up to see whats being written. I have yet to get an "o". Edited by BrookieDragon
Posted (edited)

pixelGetColor isnt returning hex value, you should change:

if PixelGetColor(252,980) = "FFFFFF" Then

to:

if hex(PixelGetColor(252,980),6) = "FFFFFF" Then

:)

Edited by Uriziel01
Posted

Thanks much, I was thinking my problem was with that. Cause all the script samples used something other then what the Autoit windows info tool was returning.

Is there an easy way to get hex using the window tool?

  Uriziel01 said:

pixelGetColor isnt returning hex value, you should change:

if PixelGetColor(252,980) = "FFFFFF" Then

to:

if hex(PixelGetColor(252,980),6) = "FFFFFF" Then

:)

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