Jump to content

Clicking on picture?


bevardis
 Share

Recommended Posts

#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("Form1", 633, 447, 193, 125)
$Pic1 = GUICtrlCreatePic("F:\AutoIt\cookie_chocchip.gif", 224, 88, 100, 100, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))
GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $Pic1
            MsgBox(0,"message", "You clicked the damned cookie")
    EndSwitch
WEnd


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

I can't use pixel sum thing because I don't know coordinates.

I have a button.bmp - a picture of how a button looks like, and I need autoIT to find the button on screen and click it.

Now, I need to click not on just button that I bet can be clicked in other ways.

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