<< Click to Display Table of Contents >> Navigation: Macros > Macro commands and parameters > Macro alteration commands > Macro command Set |
Purpose:
Assigns a value to an attribute or a variable.
General notation:
Set( Object( ObjectName ).Attribute , value )
or
Set( Variable , value )
Examples:
Change transformer 'MyTransformer' tap changer into 4:
Set( Transformer( 'MyTransformer' ).Tap , 4 )
Open cable 'MyCable' first (from-node) switch:
Set( Cable( 'MyCable' ).FirstSwitch , Open )
Close cable 'YourCable', between nodes 'Station 1' and 'Station 2' second (to-node) switch:
Set( Cable( 'YourCable:Station 1-Station 2' ).SecSwitch , Closed )
Change synchronous motor 'MyMachine' reactive power direction into "flowing into the network":
Set( SynMot( 'MyMachine' ).Qdirection , Supply )
Change load behaviour 'MyLoadBehaviour' scaling factor into 1.1:
Set( LoadBehaviour( 'MyLoadBehaviour' ).Scaling , 1.1 )
Initiate variable with name 'MyVoltage' at 10.5:
Set( MyVoltage , 10.5 )
Save node 'MyNode' p.u. voltage into variable HelpVoltage:
Set( HelpVoltage , Node( 'MyNode' ).Upu )
Save the node with name 'MyNode' into variable MonitoredNode:
Set( MonitoredNode , Node( 'MyNode' ) )
Creating or changing a Characteristic with the identifier 'Maintenance' and its Value with the text: 'Do Not Switch':
Set( Node('MyNode').Specifics , 'Maintenance=Do Not Switch' )
Deleting a Characteristic with the identifier 'Maintenance':
Set( Node('MyNode').Specifics , 'Maintenance=' )