Snglstp, Snglstp -23, Variations – Rockwell Automation 1746-BAS BASIC LANGUAGE User Manual
Page 63: Example, Purpose, Syntax

Publication 1746-RM001A-US-P
BASIC Commands 4-23
Variations
Some BASIC interpreters allow a line number to follow the RUN command
(example:
RUN 100
). The module does not permit this variation on the RUN
command.
Execution begins with the first line number. To obtain a function similar to the
RUN [ln num] command, use the GOTO [ln num] statement in the Direct mode.
See statement GOTO in chapter 7.
Example
>1
REM EXAMPLE PROGRAM
>10 FOR I = 1 TO 3
>20 PRINT I
>30 NEXT I
>40 END
>RUN
1
2
3
READY
>
SNGLSTP
Purpose
Use the SNGLSTP command to initiate single-step program execution. If the
number specified by this command is zero, single-step execution is disabled. If the
number is not zero, a break point is set before each line in the program. Start the
program by typing the RUN command. After each stop, type
CONT
to execute the
next line. You can inspect variables or assign variables at each break point.
SNGLSTP works only on programs executing from RAM. It does not stop a
program executing from EEPROM.
Syntax
SNGLSTP[integer]