Difference between revisions of "SAVE GETS"

From Recital Documentation Wiki
Jump to: navigation, search
(Class)
 
Line 1: Line 1:
 
 
 
==Purpose==
 
==Purpose==
 
Save status of current GETS
 
Save status of current GETS
Line 48: Line 46:
  
 
==Products==
 
==Products==
Recital Mirage Server, Recital Terminal Developer
+
Recital  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Commands]]
 
[[Category:Commands]]
 
[[Category:Screen Forms]]
 
[[Category:Screen Forms]]
 
[[Category:Screen Forms Commands]]
 
[[Category:Screen Forms Commands]]

Latest revision as of 16:34, 12 November 2009

Purpose

Save status of current GETS


Syntax

SAVE GETS [TO <memvar>]


See Also

@...GET, CLEAR GETS, FMT(), READ, RESTORE GETS, RESTORE SCREEN, SAVE SCREEN


Description

The SAVE GETS command lets you save a description of the GETS in the current screen form for subsequent retrieval by the RESTORE GETS command. Since the Recital/4GL allows @...GET commands to be specified within a validation routine, the SAVE GETS command is particularly useful in letting you execute a screen form in a procedure invoked by the @...GET...VALIDATE command. When the validation procedure is terminated, the READ in the calling screen form is reactivated. This process is called nesting reads.

TO <memvar>

The optional TO <memvar> clause can be used to save the active GETS to a memory variable. This allows for multiple SAVE and RESTORE GETS.


Example

// Set up validation procedure
procedure checkit
  parameters check
  save screen
  // Specify SAVE GETS and CLEAR GETS before @...gets
  save gets
  clear gets
  @0,1 get field4
  // Activate gets in validation procedure
  read
  // Reactivate reads in main screen form
  if not empty(field4)
      set validate on
  endif
  restore gets
  restore screen
return
 
@1,1 get field1
@2,1 get field2 when field1="g"
@3,1 get field3 validate with checkit
read


Products

Recital