tips:revmedia:subs18

POP.SESSION

Published ByDateVersionKnowledge LevelKeywords
Revelation Technologies14 NOV 19892.XEXPERTPOP.SESSION

POP.SESSION is a subroutine that restores the environment parameters saved by a preceding call to PUSH.SESSION.

POP.SESSION(cursor.loc, sentence, record, id, dict, mv)

Use POP.SESSION to restore an environment after use of PUSH.SESSION. The saved values are passed from the PUSH.SESSION argument list.

cursor.loc

Use cursor.loc to pass the cursor position saved by PUSH.SESSION.

sentence

Use sentence to pass the TCL sentence saved by PUSH.SESSION.

record

Use record to pass the record saved by PUSH.SESSION

id

Use id to pass the record key saved by PUSH.SESSION.

dict

Use dict to pass the dictionary variable saved by PUSH.SESSION.

mv

Use mv to pass the array of @MV, @INSERT (see Appendix 1, "System Variables"), and video attributes saved by PUSH.SESSION.

None.

* The following code restores an environment preserved by PUSH.SESSION

DECLARE SUBROUTINE PUSH.SESSION, POP.SESSION, MSG

PUSH.SESSION(cursor, sentence, record, id, dict, mv)

* Call a subroutine that modifies environment parameters.

GOSUB change.environ

text     = "The modified values are:"
text<<-1>> = "SENTENCE is ":@SENTENCE
text<<-1>> = "RECORD is ":@RECORD
text<<-1>> = "ID is ":@ID

MSG(text, "", "", "")

POP.SESSION(cursor, sentence, record, id, dict, mv)

text     = "The restored values are:"
text<<-1>> = "SENTENCE is ":@SENTENCE
text<<-1>> = "RECORD is ":@RECORD
text<<-1>> = "ID is ":@ID

MSG(text, "", "", "")

STOP

/* Assign sample values to system variables referenced by 
the environment parameters */

change.environ:

@@SENTENCE = "SELECT SAMPLE.FILE BY ST BY ZIP"
@@RECORD   = "SAMPLE"
@@ID       = "SAMPLE.ID"

RETURN
  • tips/revmedia/subs18.txt
  • Last modified: 2024/06/19 20:20
  • by 127.0.0.1