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.

Newcomers DBPro Corner / Little error in my first DB program

Author
Message
uknumba1
13
Years of Service
User Offline
Joined: 7th May 2011
Location:
Posted: 8th May 2011 05:33
My error is at this line of code: for y = 1 to 24

The error states: Command out of place at line 111. Compilation failed (Syntax Errors)

Dar13
16
Years of Service
User Offline
Joined: 12th May 2008
Location: Microsoft VisualStudio 2010 Professional
Posted: 8th May 2011 05:57 Edited at: 8th May 2011 06:13

You have used both ways to end an if-statement(if-then, if-endif) when you can only use one.
Here's the correct code:





Kezzla
16
Years of Service
User Offline
Joined: 21st Aug 2008
Location: Where beer does flow and men chunder
Posted: 8th May 2011 06:00
the problem is with your use of the if then statement.
if you are using a single line if statement then you use 'then'
if you are using a multi line if statement then you dont use 'then'

eg

single line


multiple lines



so yours should be


Sometimes I like to use words out of contents

Login to post a reply

Server time is: 2024-11-22 23:06:05
Your offset time is: 2024-11-22 23:06:05