Proc Reference > PQN Proc Commands > IF S

Comment on this topic

Documentation Comments

Use this form to comment on this topic. You can also provide any general observations about the Online Documentation, or request that additional information be added in a future release.

RealityV15.1Online Documentation (MoTW) Revision 7

IF S command (Proc) (m618403+ifs.htm)

To

Reality

Version

Topic

Submitted by

Company

Location

Email address

Comment

 

 

IF S

Conditionally executes a Proc command based on the presence or absence of an active select list.

Syntax

IF {#} S command

Syntax elements

# tests for the absence of a select list.

command is a valid Proc command.

Operation

IF S command executes command if a select list is active.

IF # S command executes command if no select list is active.

Examples

PQN
IF S G F
1 OEnter list name +
IP %1
IF # %1 G 1
HGET-LIST
A1
STON
M
HPQ-SELECT 1
P
M
MV %1 !1
IF # %1 G F
T %1
G B
M OAll Item-Ids Output
X

This Proc checks for an active list. If one exists, it is read into select register 1. If there is no active list, the user is prompted for a list name. Once a list is retrieved, its item-ids are output in turn before the Proc terminates.

IF # S G 200
IP?
.
.
.

If there is no active select list, go to label 200; otherwise prompt for input.

RealityV15.1 (MoTW) Revision 7Comment on this topic