EasyManuals Logo

Tektronix KEITHLEY 2600B Series User Manual

Tektronix KEITHLEY 2600B Series
834 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #503 background imageLoading...
Page #503 background image
Section 9: TSP command reference Series 2600B System SourceMeter® instrument Reference Manual
9-182 2600BS-901-01 Rev. F/August 2021
script.newautorun()
This function creates a script and enables autorun.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Function
No
Usage
scriptVar = script.newautorun("code")
scriptVar = script.newautorun("code", "name")
scriptVar
The name of the variable that references the script
code
A string that contains the body of the script
name
The name of the script
Details
The name parameter is the name that is added to the script.user.scripts table. If name is not
provided, an empty string is used, and the script is unnamed. If the name already exists in
script.user.scripts, the name attribute of the existing script is set to an empty string before it is
replaced by the new script.
Note that name is the value that is used for the instrument front panel display. If this value is not
defined, the script is not available from the front panel.
You must save the new script into nonvolatile memory to keep it when the instrument is turned off.
The script is run automatically immediately after it is created.
This command is the same as the script.new() function except that the script is automatically run.
Example
NewAuto = script.newautorun("print('Hello from new auto run command')", 'NewAuto')
print(NewAuto.autorun)
print(NewAuto.name)
Creates a new script called NewAuto that automatically has the autorun attribute set to yes after it is created.
The name is set to NewAuto.
Output:
Hello from new auto run command
yes
NewAuto
Also see
Create a script using the script.new() command (on page 8-76)
Global variables and the script.user.scripts table (on page 8-74)
Named scripts (on page 8-4)
script.new() (on page 9-181)
scriptVar.autorun (on page 9-184)
scriptVar.save() (on page 9-188)

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tektronix KEITHLEY 2600B Series and is the answer not in the manual?

Tektronix KEITHLEY 2600B Series Specifications

General IconGeneral
BrandTektronix
ModelKEITHLEY 2600B Series
CategoryMeasuring Instruments
LanguageEnglish

Related product manuals