WORKSTATIONNAME
If the ViewX clients on your system are each assigned a Workstation Name, you can reference this in expressions, for example for use in Mimic animations. To do this, use the WORKSTATIONNAME function to return the Workstation Name that is assigned to the ViewX client on which the expression is being used. This function can be useful when using expressions to set up different functionality per workstation/ViewX client.
A ViewX client might be assigned multiple workstation names (one per Geo SCADA Expert database). The Workstation Name that is returned is the one that applies for the Geo SCADA Expert database in which the Mimic exists. The Workstation Name property is local to the client and does not require a server call.
In displays that are accessed from a Virtual ViewX server, the WORKSTATIONNAME function will return an empty string. This is because Workstation Names should only be used for ViewX clients (as opposed to Virtual ViewX clients) and have to be unique on the system. Therefore, the Workstation Name will be blank in the connection settings for a Virtual ViewX server.
The WORKSTATION function is only available in client expressions. It cannot be used in server expressions.
Function Name |
WORKSTATIONNAME |
Description |
Returns the Workstation Name that is assigned to the ViewX client on which the expression is used, or an empty string if the Workstation Name field is unpopulated on the client. |
Arguments |
WORKSTATIONNAME() |
Returns |
STRING The Workstation Name of the ViewX client on which the expression is used, or an empty string if the Workstation Name field is unpopulated on the client. |
The FillColour of a Button on a Mimic is animated to display a different background color, depending on the name of the workstation (ViewX client) on which the Mimic is displayed. The following expression is used for animating the button's FillColour:
IIF (WorkstationName()='Zone 1 Workstation', RGB(255,242,0), RGB(0,162,232))
If one user logs in to more than one ViewX workstation, you can use the WORKSTATIONNAME function in conjunction with the Geo SCADA User Registry to create different Registry variables per workstation. Give the custom registry variables a name such as:
WorkstationName()+'<VariableName>'