phuzE koj Posted January 24, 2006 Share Posted January 24, 2006 (edited) Okay, this is a little hard to explain, but here it goes: Is there a way to: 1. Check the color of pixel 0,0 2. Move the mouse to a certain pixel...say for instance 1024,760 3. Then once on the pixel, to check and see if the color of pixel 0,0 has changed. 4. Then if both are true to Send("{F7}") Sorry if this question is confusing. I'm a little new to autoit, and I could piece together small parts here and there, but couldn't fit it together. Would anyone mind showin me what this code might look like if it's not too much trouble? //thanks in advance edit: rephrased question. Edited January 24, 2006 by phuzE koj Link to comment Share on other sites More sharing options...
PsaltyDS Posted January 24, 2006 Share Posted January 24, 2006 Okay, this is a little hard to explain, but here it goes:Is there a way to:1. Move the mouse to a certain pixel...say for instance 1024,7602. Then once on the pixel, to check and see if there is a certain change (or to see if certain text exists; "name" for example) on ...say 0,03. Then if both are true to Send("{F7}")Sorry if this question is confusing. I'm a little new to autoit, and I could piece together small parts here and there, but couldn't fit it together.Would anyone mind showin me what this code might look like if it's not too much trouble?//thanks in advanceA pixel can't have text on it, except in a metaphysical "angel on the head of a pin" sense. It takes many pixels to make text. AutoIT can read the color of a single pixel, but can't tell what kind of text, or picture, or icon, or wallpaper that pixel might be part of. It would be easy to move the mouse to x,y and see if the color of that pixel matches the pixel at a,b. But that has nothing to do with text that the pixel may, or may not, be part of. You'll have to define the problem much better to get any solution. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
AutoChris Posted January 24, 2006 Share Posted January 24, 2006 Okay, this is a little hard to explain, but here it goes:Is there a way to:1. Check the color of pixel 0,02. Move the mouse to a certain pixel...say for instance 1024,7603. Then once on the pixel, to check and see if the color of pixel 0,0 has changed.4. Then if both are true to Send("{F7}")Sorry if this question is confusing. I'm a little new to autoit, and I could piece together small parts here and there, but couldn't fit it together.Would anyone mind showin me what this code might look like if it's not too much trouble?//thanks in advanceedit: rephrased question.Not sure I really understand what you are asking....$Color_1 = PixelGetColor (0, 0)$Color_2 = PixelGetColor (1024, 760)If $Color_1 = $Color_2 Then MsgBox (0, "Same", "You are golden!")Else MsgBox (0, "Different", "Sorry, Charlie")EndIf Link to comment Share on other sites More sharing options...
phuzE koj Posted January 24, 2006 Author Share Posted January 24, 2006 Not sure I really understand what you are asking....$Color_1 = PixelGetColor (0, 0)$Color_2 = PixelGetColor (1024, 760)If $Color_1 = $Color_2 Then MsgBox (0, "Same", "You are golden!")Else MsgBox (0, "Different", "Sorry, Charlie")EndIfThat's nearly what I'm talking about, except I want the mouse cursor to physically move to 1024,760. And THEN after that's complete, to RECHECK 0,0 and see if it's changed. Hopefully that clears things up. Thanks for the reply though. Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted January 24, 2006 Share Posted January 24, 2006 (edited) $Color_1 = PixelGetColor (0, 0) $Color_2 = PixelGetColor (1024, 760) Movemouse(1024,760) If $Color_1 = $Color_2 Then MsgBox (0, "Same", "You are golden!") Else Movemouse(0,0) EndIf just add in a mousemove yeah i just kinda tossed them in so yeah put it where u want Edited January 24, 2006 by thatsgreat2345 Link to comment Share on other sites More sharing options...
phuzE koj Posted January 25, 2006 Author Share Posted January 25, 2006 cool, it worked, thanks for the help btw - it is MouseMove not Movemouse. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted January 25, 2006 Moderators Share Posted January 25, 2006 cool, it worked, thanks for the helpbtw - it is MouseMove not Movemouse. 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...
Thatsgreat2345 Posted January 25, 2006 Share Posted January 25, 2006 OMG i uh just accidently typed movemouse instead of mousemove i have no idea what i was thinkng Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted January 25, 2006 Moderators Share Posted January 25, 2006 OMG i uh just accidently typed movemouse instead of mousemove i have no idea what i was thinkngNo worries!! You probably just read his post:2. Move the mouseAnd had that stuck in your head on what he was wanting to accomplish when you were writing it. 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...
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