ArmandoXS 0 Posted April 18, 2010 Here is a piece of a program im making: If Not @error Then $timer=TimerInit() $cord=PixelSearch(133,103,888,656,0xA58A29,10,10) MouseClick("left",$cord[1],$cord[2],1,1) Sleep(12000) The error is, ==> Subscript used with non-Array variable.: MouseClick("left",$cord[1],$cord[2],1,1) MouseClick("left",$cord^ ERROR Any way i can fix or get around this problem? Share this post Link to post Share on other sites
trancexx 1,013 Posted April 18, 2010 Add error checking for PixelSearch(). ♡♡♡ . eMyvnE Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 Add error checking for PixelSearch().error checking???? Share this post Link to post Share on other sites
trancexx 1,013 Posted April 18, 2010 I was kidding. ♡♡♡ . eMyvnE Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 I was kidding.umm.... ok..... Share this post Link to post Share on other sites
trancexx 1,013 Posted April 18, 2010 I was lying. ♡♡♡ . eMyvnE Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 kidding, lol DarkDragon Icon, you cant possibly not know what error checking is, as you clearly have it in your code already for some absent psrt of your script. There are a number of ways to check for an error with that function, even in the helpfile documentation for the function believe it or not. @error or you can look at IsArray() AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
trancexx 1,013 Posted April 18, 2010 kidding, lolDarkDragon Icon, you cant possibly not know what error checking is, as you clearly have it in your code already for some absent psrt of your script.There are a number of ways to check for an error with that function, even in the helpfile documentation for the function believe it or not.@erroror you can look at IsArray()Sweet talker. ♡♡♡ . eMyvnE Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 kidding, lolDarkDragon Icon, you cant possibly not know what error checking is, as you clearly have it in your code already for some absent psrt of your script.There are a number of ways to check for an error with that function, even in the helpfile documentation for the function believe it or not.@erroror you can look at IsArray()Still a little fuzzy on that answer but ill look in the"help file documentation" Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 (edited) Sweet talker.Charm the knickers of a nun @ 100 yards me Edited April 18, 2010 by JohnOne AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 (edited) In the code you posted, what does this do ? "If Not @error Then" ?edit: Typo Edited April 18, 2010 by JohnOne AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 If you can please provide a link, when i said i was a little fuzzy i meant i was completly confused Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 In the cose you posted, what does this do ? "If Not @error Then" ?theres another pixelsearch command before the code i provided Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 theres another pixelsearch command before the code i providedOk, so how is the next pixelsearch any different ? AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 Ok, so how is the next pixelsearch any different ?i have no idea but if u need me to post the whole code i can Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 No, thats OK, I just want you to click what you're being told, i'tt be better in the long run. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 No, thats OK, I just want you to click what you're being told, i'tt be better in the long run.??????anyway do you have a link for the place where i can find information on where i can get help Share this post Link to post Share on other sites
trancexx 1,013 Posted April 18, 2010 ??????anyway do you have a link for the place where i can find information on where i can get helpWait, wait...What exactly you want link for? ♡♡♡ . eMyvnE Share this post Link to post Share on other sites
ArmandoXS 0 Posted April 18, 2010 Wait, wait...What exactly you want link for?JohnOne talked about something in the help file documentation Share this post Link to post Share on other sites
JohnOne 1,603 Posted April 18, 2010 Lets go back a little and see if you can answer the question a little better. In the code you posted, what does this do ? "If Not @error Then" ? I know you said there is a pixel search ealier in the code , but can you tell me whay you have that line, and what it does ? AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites