Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / problem that it wont let me close nest on ###

Author
Message
slipkorn624
15
Years of Service
User Offline
Joined: 20th May 2011
Location:
Posted: 20th May 2011 16:13
so when i launch the game it says could not close nest at line 608. my teacher said to look through the code to find an if/end if statement that's out of place.i cant find any that are out of place. help? wont let me put the code or the attachments in because of bad language. so if you can help please send me a message or email me at [email protected]. thanks if you can help!
Grog Grueslayer
Valued Member
21
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 20th May 2011 16:33
Without seeing your code the easiest way to find it yourself is to indent your code (with spacing or tab). When you indent you line up the beginning of a statement and the end of statement of all DO/LOOPs, IF/ENDIF, REPEAT/UNTIL, FOR/NEXT and so on giving you greater visibility for any nesting problems. I personally only use one space but most people hit TAB instead.



Attila
FPSC Reloaded TGC Backer
21
Years of Service
User Offline
Joined: 17th Aug 2004
Location:
Posted: 20th May 2011 17:04 Edited at: 20th May 2011 17:04
I tested your program, it worked fine and produced the output as seen on the attached screenprint

Grog Grueslayer
Valued Member
21
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 21st May 2011 10:35
Uh, yeah. I wasn't asking for help on that code I was showing slipkorn624 how code is indented by posting some code that's indented.

Login to post a reply

Server time is: 2026-07-11 04:23:40
Your offset time is: 2026-07-11 04:23:40