Scriptvar.name - Keithley 3700A Series Reference Manual

System switch/multimeter
Hide thumbs Also See for 3700A Series:
Table of Contents

Advertisement

Series 3700A System Switch/Multimeter Reference Manual
Details
This function generates output in the form of a sequence of response messages (one message for
each line of the script). It also generates output of the script control messages (loadscript or
loadandrunscript and endscript).
Example
test7 = script.new("display.clear() display.settext('Hello from my test')",
"test7")
test7()
test7.save()
test7.list()
The above example code creates a script named test7 that displays text on the front panel and lists the script
with the following output:
loadscript test7
display.clear() display.settext("Hello from my test")
endscript
Also see
Load a script by sending commands over the remote interface
Retrieve source code one line at a time

scriptVar.name

This attribute contains the name of a script in the run-time environment.
Type
TSP-Link accessible
Attribute (RW)
No
Usage
scriptVar.name = scriptName
scriptName = scriptVar.name
scriptVar
scriptName
Details
When setting the script name, this attribute renames the script that the variable scriptVar
references.
This attribute must be either a valid Lua identifier or the empty string. Changing the name of a script
changes the index that is used to access the script in the script.user.scripts table. Setting the
attribute to an empty string removes the script from the table completely, and the script becomes an
unnamed script.
As long as there are variables referencing an unnamed script, the script can be accessed through
those variables. When all variables that reference an unnamed script are removed, the script will be
removed from the run-time environment.
If the new name is the same as a name that is already used for another script, the name of the other
script is set to an empty string, and that script becomes unnamed.
3700AS-901-01 Rev. D/June 2018
(on page 10-8)
Affected by
Not applicable
Name of the variable that references the script
A string that represents the name of the script
Section 11: TSP command reference
(on page 10-4)
Where saved
Default value
Not applicable
Not applicable
11-349

Advertisement

Table of Contents
loading

Table of Contents