SaveAsTclCommand Object


Description:

Saves the current configuration as one or two Tcl files that use Spirent TestCenter Automation commands.

Can be used with Command Sequencer: No

Parents: Sequencer, StcSystem

SaveAsTclCommand Writable Attributes

Attribute Description
Common Writable Attributes Active, Name, ProgressCancelled
BeforeDisconnectScript

An optional Tcl script to run with the generated script before disconnecting from the Spirent TestCenter chassis.

Type: string

Default: "" (empty string)

Config

Handle of the portion of the configuration to save. The default of 1 means system1, which is the root object of the entire configuration.

Type: handle

Default: 1

FileName

File name to use for the script.

Type: outputFilePath

Default: config.tcl

PathReplacements

Path to replace system file path for output files.

Type: string

Default: "" (empty string)

ProcedurePrefix

A prefix to prepend to the generated Tcl procedures to ensure uniqueness.

Type: string

Default: "" (empty string)

SaveDefault

All objects and attributes are included in the XML file, unless set to false. If set to false, then only objects and attributes that are changed from their default settings will be included in the XML file.

Type: bool

Default: TRUE

Possible Values:

Value Description
TRUE

All objects and attributes are included in the XML file.

FALSE

Only objects and attributes that are changed from their default settings will be included in the XML file.

TclNamespace

Namespace for procs and global variables for tcl script.

Type: string

Default: "" (empty string)

UseDefaultsForRarelyUsedSettings

Select this to further reduce the amount of code in the saved script. Spirent TestCenter automatically creates a number of objects, and some of these do not use default values. If you select this option, these objects are left out of the saved script. They will still be created when the script is run.

Type: bool

Default: FALSE

Possible Values:

Value Description
TRUE

If true, default values will be used instead of user configured ones for certain rarely used settings.

FALSE

If false, user configured values will be used for certain rarely used settings.

SaveAsTclCommand Read-Only Attributes

Read-Only Attribute Description
Common Read-Only Attributes ElapsedTime, EndTime, ProgressCurrentStep, ProgressCurrentStepName, ProgressCurrentValue, ProgressDisplayCounter, ProgressMaxValue, ProgressStepsCount, StartTime, State, Status