Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

Conditional EndProg?


RyanBares Aug 19, 2014 08:25 PM

Can you make a CRBasic program end on a conditional statement?

For instance...

If (Done = 1) Then
NextScan
Else
EndProg

Or something along those lines? I tried the above code but it failed to compile.


Dana Aug 19, 2014 09:20 PM

I think you should be able to ExitScan, which would effectively end the execution of the program.

Dana


jra Aug 20, 2014 02:15 PM

Also take a look at the ContinueScan instruction. ContinueScan jumps you to the NextScan instruction; so the program will continue to run at the top of the next Scan interval.


RyanBares Aug 20, 2014 05:13 PM

Thanks! I It looks like both options work great.

Ryan

Log in or register to post/reply in the forum.