Josh 37 Posted March 2, 2012 Report Share Posted March 2, 2012 So I just opened up a script I had save in Ubot, and it's in code view. I clicked the button to go to node view and I got an error message pop up. "There is an error in your code. Please fix it before switching to node view." So my question is, how do I find where the error is? Is there some way of having ubot highlight the error? I am not familiar enough with ubot yet to be able to do this. Quote Link to post Share on other sites
Legend 181 Posted March 3, 2012 Report Share Posted March 3, 2012 Usually they are underlined in red... if not you need to locate it yourself. One way to do that is to copy the code to a text file and paste fragments of it back in, one at a time, checking to see if node view is available each time... this should help to locate the problem. http://ubotstudio.com/forum/public/style_emoticons/default/tongue.gif Quote Link to post Share on other sites
Josh 37 Posted March 5, 2012 Author Report Share Posted March 5, 2012 Thanks for the info. I don't see anything underlined in red which means I have to check it. This is such a pain because this bot is pretty big! Quote Link to post Share on other sites
JohnB 255 Posted March 5, 2012 Report Share Posted March 5, 2012 You can look first for things like define nodes that are not named, empty if/then statements, etc. It is most often an incomplete command. John Quote Link to post Share on other sites
Chainsaw 9 Posted March 5, 2012 Report Share Posted March 5, 2012 Thanks for the info. I don't see anything underlined in red which means I have to check it. This is such a pain because this bot is pretty big! In these kind of situations, sometimes you need to make a backup copy and then start cutting your code in half. Step 1. Save a temporary version of the codeStep 2. Find a suitable break point about half way through your code and delete half the code.Step 3. If you still can't get to Node View find goto Step 1.Step 4. If you can get to Node View, then reload the last temporary version and delete the other half of the code.Step 5. Goto Step 1. No matter how many lines of code you have, this approach will zero in on the problem code pretty quickly. Quote Link to post Share on other sites
Josh 37 Posted March 5, 2012 Author Report Share Posted March 5, 2012 No matter how many lines of code you have, this approach will zero in on the problem code pretty quickly. Yup That's pretty much what I did. Using dreamweaver helped because it helped me to see the formatting better than a txt file. Quote Link to post Share on other sites
winincome 3 Posted April 1, 2012 Report Share Posted April 1, 2012 if you have two erros one at the top and one low done in you code this may not work so if things are puzzling consider the fact you may have more than one error. Quote Link to post Share on other sites
orbital 15 Posted May 11, 2013 Report Share Posted May 11, 2013 I appreciate this thread as it helped me figure out where the error was. There was actually no error in the code I just forgot to add the plugin the code was using after I did a fresh install of the OS. Quote Link to post Share on other sites
hienquoc 3 Posted May 4, 2018 Report Share Posted May 4, 2018 ok i had this problem too, but i realized i had a define function with 3 inputs, i had created an alert with 3 inputs to test the function. I then modified later to have 4 inputs in the define but i left the alert with the 3 inputs calling the same define, so that was the error. But it wont show anything visual for me to check. So if anyone of you remember doing this, just go back and delete the call for the function or command with mismatch inputs. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.