Subprogram Command Types; Definition/Deletion Commands; Sub/Subend; Delsub - Agilent Technologies 3458A User Manual

Hide thumbs Also See for 3458A:
Table of Contents

Advertisement

The subprogram will not be stored if a subprogram nesting error exists when
the SUBEND command is executed (e.g., if one of the called subprograms
does not exist in 3458A memory).
If you create or download a subprogram using a subprogram name which
already exists in 3458A memory, the new subprogram overwrites the
previous subprogram.

Subprogram Command Types

The 3458A's subprogram-related commands are used only within
subprograms. Subprogram definition and deletion commands deal with the
storage. viewing, and deletion of subprograms from internal memory.
Execution commands control execution of subprograms from inside or
outside a subprogram.
Definition/Deletion
Subprogram definition and deletion commands identify the beginning and
end of subprograms, store and delete subprograms from memory, and list the
Commands
subprograms presently stored in internal memory.
The syntax statements for the subprogram definition and deletion commands
are shown below.
SUB sub_name
SUBEND
DELSUB sub_name
SCRATCH
CAT
LlST sub_name
COMPRESS sub_name

SUB/SUBEND

Every 3458A subprogram must contain a SUB and SUBEND command. The
SUB command must be the first line in all 3458A subprograms. It identifies
where the subprogram begins and assigns the name to the subprogram. When
the SUB command is executed, the 3458A begins storing the subprogram in
internal memory.
The SUBEND command must be the last line in all 3458A subprograms. It
identifies where the subprogram ends and also terminates the entry of the
subprogram. Commands listed between the SUB and SUBEND commands
are executed, in order, every time the subprogram is executed.
Only one SUB and one SUBEND command is allowed in any one
subprogram. Additional SUB or SUBEND commands will generate errors.

DELSUB

The DELSUB (delete subprogram) command deletes the specified
subprogram from internal memory but does not delete the subprogram name
Chapter 7 BASIC Language for the 3458A
275

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents