Linux Posted July 31, 2008 Share Posted July 31, 2008 (edited) hi all. In the script i made, i get this error in a msgbox after compiled. Line-1: Error:Array variable has incorrect number of subscripts or subscript dimension range exceeded my script automate a website, and i have to store some key tables of the script. is there any way to disable the msgbox and keep the script running after the error? I searched the forum but i found nothing Edited July 31, 2008 by Linux You can help! Donate to AutoIt! or, visit ClimatePREDICTION.netMy posts:Travian Bot Example (100+ servers) BETAHow to Host you code/app for free! (unlimited team number) (Public or Private)"Sir, we're surrounded!" "Excellent. We can attack in any direction!" Link to comment Share on other sites More sharing options...
TerarinKerowyn Posted July 31, 2008 Share Posted July 31, 2008 What script is it? usually the $variable[<number wrong here>] is it Contact via MSN: [email=terarink_msn@hotmail.com]terarink_msn@hotmail.com[/email], yahoo: terarink_yah Link to comment Share on other sites More sharing options...
Achilles Posted July 31, 2008 Share Posted July 31, 2008 If it's getting that error then I'm guessing it's not running right when you run it from Scite... My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
TerarinKerowyn Posted July 31, 2008 Share Posted July 31, 2008 did you have any Dim Local Global of a array without redim it or to low of a number for your array Contact via MSN: [email=terarink_msn@hotmail.com]terarink_msn@hotmail.com[/email], yahoo: terarink_yah Link to comment Share on other sites More sharing options...
Richard Robertson Posted July 31, 2008 Share Posted July 31, 2008 If there is an error then you are doing something wrong. Before you try to access a value, make sure the value exists and is accessible. Link to comment Share on other sites More sharing options...
Linux Posted July 31, 2008 Author Share Posted July 31, 2008 $TempArray = _StringBetween($array_temp[0], "<TD>", "</") If IsArray($TempArray) Then You can help! Donate to AutoIt! or, visit ClimatePREDICTION.netMy posts:Travian Bot Example (100+ servers) BETAHow to Host you code/app for free! (unlimited team number) (Public or Private)"Sir, we're surrounded!" "Excellent. We can attack in any direction!" Link to comment Share on other sites More sharing options...
TerarinKerowyn Posted July 31, 2008 Share Posted July 31, 2008 What is the $array_temp[0] Dim as? Does it exist or any values given to it? Contact via MSN: [email=terarink_msn@hotmail.com]terarink_msn@hotmail.com[/email], yahoo: terarink_yah Link to comment Share on other sites More sharing options...
rasim Posted July 31, 2008 Share Posted July 31, 2008 LinuxOr check returned value:$TempArray = _StringBetween($array_temp[0], "<TD>", "</") If @error Then Return SetError(1, 0, 0) Link to comment Share on other sites More sharing options...
Linux Posted July 31, 2008 Author Share Posted July 31, 2008 thank you rasim, I will try to add that. A bigger example of my code: $array_temp = _StringBetween($Source, "img/un/a/del.gif", "</span></td></tr>") If IsArray($array_temp) Then ;save data to the slot $TempArray = _StringBetween($array_temp[0], "<TD>", "</") If IsArray($TempArray) Then $TempArray[1] = StringTrimRight(StringRight($TempArray[1], 8), 3) If Number(StringLeft($TempArray[1], 1)) = 0 Then $TempArray[1] = StringTrimLeft($TempArray[1], 1) $TempArray[2] = StringRight($TempArray[2], 5) You can help! Donate to AutoIt! or, visit ClimatePREDICTION.netMy posts:Travian Bot Example (100+ servers) BETAHow to Host you code/app for free! (unlimited team number) (Public or Private)"Sir, we're surrounded!" "Excellent. We can attack in any direction!" 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