Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › AutoHotKey ImageSearch Help
New Posts  All Forums:Forum Nav:

AutoHotKey ImageSearch Help

post #1 of 2
Thread Starter 
Hey there,

I have been trying to get this ImageSearch function to work in AHK, but I keep receiving the following error(sown below) no matter how many things I try. If there is someone that could take a look over this, it would be greatly appreciated.
Code:
ButtonTermination:
IfNotExist C:\MyImages\AddNote.jpg
   MsgBox File not found.
ifWinExist Assignment
{
WinActivate Assignment
MouseClick, left, 342,24
MouseClick, left, 51,311
Send Looked up user in admin tool {enter} Changed password {enter} Disabled account {enter} Closing ticket

CoordMode, Pixel, Screen
ImageSearch, x, y, 0, 0, A_ScreenWidth, A_ScreenHeight, *165 C:\MyImages\AddNote.jpg
if ErrorLevel = 2
    MsgBox Could not conduct the search.
else if ErrorLevel = 1
    MsgBox Icon could not be found on the screen.
else
    MsgBox The icon was found at %x%x%x%
Sleep 5000
MouseClick, left
Sleep 100
MouseClick, left, 96,184
MouseClick, left, 73,445
Send Looked up user in admin tool {enter} Changed password {enter} Disabled account {enter} Closing ticket
MouseClick, left, 385,517
MouseClick, left, 786,249
Send %technician% {enter}
MouseClick, left, 416,64
MouseClick, left, 52,69
return
}
else
MsgBox Please open a Termination ticket
return


Edited by XiCynx - 8/14/13 at 11:43am
post #2 of 2
Thread Starter 
Bump

Nothing? frown.gif Dang, guess I'll have t find a place better associated with AHK.
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Coding and Programming
Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › AutoHotKey ImageSearch Help