qb45advr.hlp (Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
STOP Statement Details
  QuickSCREEN      Details      Example      Contents      Index
──────────────────────────────────────────────────────────────────────────────
STOP Statement Details
 
Syntax
  STOP
 
STOP statements can be used anywhere in a program to terminate
execution.
 
When running in the QuickBASIC environment, the STOP statement leaves
files open and does not exit to the operating system. In contrast, a
STOP statement in a stand-alone .EXE file does close all files and
return to the operating system.
 
If you use the /D, /E, or /X compile options on the BC command line,
the STOP statement prints the number of the line where execution
stopped, if your program has line numbers. If there is no line number
associated with the STOP statement, the most recent line number is
printed. If your program has no line numbers, then the line number
printed is 0.
 
In the past, STOP statements were used for debugging. QuickBASIC's
new debugging features make this use of STOP unnecessary.