Program termination: Difference between revisions

Line 1,217:
''CBTJD'': 2020/03/15<br>
There are three commands that can be used to end a program in QB64:<br>
1) END - The program will display "Press any key to continue..." and wait for a keypresskey press before closing the program.<br>
2) STOP - The program will close immediately, but will not close any open files. STOP is ONLY used for debugging purposes and should not be used to exit programs!<br>
3) SYSTEM - The ONLY proper command to immediately close a program in QB64 without a pause or interactive message as in the case with the END command.<br>
<lang qbasic>INPUT "Press any key to contine...", a$
IF 1 THEN SYSTEM</lang>
 
306

edits