caveman Posted November 2, 2007 Share Posted November 2, 2007 As the title indicates, i am trying to do a little macro which must use the hexadecimal input but the compiler does not accept the entry.but if I use decimal input everything is find.So to not lose from precision i want to use hexadecimal (and not a conversion). Can someone help me how to resolve the problem? hee is the bloc of instruction: Dim $var, $X, $Y search() ;MsgBox (0 , "color", $var) If $var = A4AF66 Then ; +++++++++++this is the line where the problem occurs MouseClick ("left", $X, $Y, 1 ,1) EndIf Func search() $X = Random (0, 1024, 1) $Y = Random (0, 768, 1) $var = Hex(PixelGetColor( $X, $Y)) EndFunc thank you Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted November 2, 2007 Moderators Share Posted November 2, 2007 $var = PixelGetColor($x, $y) If ($var == 0xA4AF66) Then Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
caveman Posted November 2, 2007 Author Share Posted November 2, 2007 $var = PixelGetColor($x, $y)If ($var == 0xA4AF66) Thenit's working....i thank to you Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now