SetupRestore()
SetupRestore()
Type: REGULAR FUNCTION
Purpose: Recalls a selected group of experimental parameters that have previously been stored in a disk file.
It is equivalent to a Setup() function in which the user chooses to restore an experimental parameter set. The major differences are in SetupSave() where no dialog box is displayed, and the user need not take any action to recall the setup parameters.
NOTE: In the Gamry Framework™, a file used to store experimental parameters can contain more than one set of parameters. Each set of parameters is stored in a separate section of the file. The sections are identified by a SetupName. In the ASCII Setup file, the SetupName that precedes each section is enclosed in square brackets (e.g., [Test 5] ).
The value of each object is in a string of the form:
Tag = Data
As examples, these lines were taken from a saved Setup() file:
[POLRES]
PSTAT=0
TITLE=Polarization Resistance
OUTPUT=My data file.DTA
NOTES=1
NOTES_LINE_0=dummy cell
VINIT=-0.02, T
VFINAL=0.02, T
SCANRATE=0.2
An object must have a dialog license to be used in SetupRestore(). A License Error dialog box is displayed if you attempt to SetupRestore() an invalid variable or object.
No error indication occurs if you try to restore an object and its Tag is not found in the SetupName section of the Setup file. The old setting for the object is not changed.
Usage: Status = SetupRestore(FileName, SetName, Item1, Item2, Item3, ….)
FileName | STRING | Pathname to the Setup file. | |
SetName | STRING | Name of the section in the Setup file. | |
ItemN | OBJECT | Object of any class with a Dialog License. | |
Status | BOOL |
TRUE if Setup file opened and field name FALSE if file cannot be opened or field name is invalid |
Comments are closed.