WatchExpressions.Insert
- Updated2024-10-09
- 2 minute(s) read
WatchExpressions.Insert
Syntax
WatchExpressions.Insert( beforePos = NULL, [clientSequenceFileParam], [insertInEngine])
Return Value
The newly created watch expression.
Purpose
Adds a new item to the collection and inserts it into the watch expression list.
Remarks
The TestStand Engine maintains a list of watch expressions. The engine automatically evaluates watch expressions with conditional break settings during execution. The engine only monitors for value changes in watch expressions for which the current sequence context matches the scope the WatchExpression.ClientSequenceFile , WatchExpression.ExecutionScope and WatchExpression.SequenceScope properties define. To add the newly created watch expression to the watch expression list the engine maintains, pass True for the insertInEngine parameter.
If the Engine.PersistWatchExpressions property is True , the engine associates the list of watch expressions with the current workspace. When you change the current workspace, the engine automatically saves the current watch expression list associated with the new workspace. The engine saves the watch expression list every time TestStand saves the workspace or sequence files in it.
Parameters
beforePos As WatchExpression
[In] Specifies a reference to a WatchExpression object already in the list to specify the object before which TestStand inserts the new WatchExpression object. Pass NULL to insert the new object at the end of the list.
This parameter has a default value of NULL .
clientSequenceFileParam As Variant
[In] [ Optional ] Specifies the client sequence file to associate with the newly created WatchExpression object. Pass NULL to create a global watch expression, a watch expression associated with no client sequence file. If this parameter is not specified, the parameter defaults to NULL .
insertInEngine As Variant
[In] [ Optional ] Specifies whether to insert the new WatchExpression object in the watch expression list the engine maintains. Pass True to add the watch expression to the collection and to the watch expression list the engine maintains. Pass False to add only the new watch expression to the collection. If no value is specified, the behavior is the same as passing True .
See Also
Engine.PersistWatchExpressions
WatchExpression.ClientSequenceFile