Network Values Variables and the Network Values Service

VTS features a Network Values service, and Network Value variables, the purpose of which is to update changes on all PCs for remote applications when a change to a Network Value variable has occurred.

Network Value variables cannot be used in a steady state.

Note: If your client is isolated from the server, and changes have occurred to Network Value variables, the client's changes will be overwritten when a reconnection to the server has been made.

Network Value variables are defined within the NetworkValue class, and are updated whenever the value for these variables changes on a client or server workstation. Network Value variables can store any value that you can Pack. (see note) Unlike Retained variables, Network Value variables recognize array element changes, and will update such changes accordingly. It should be noted however that Network Value variables won't see multi-dimensional arrays; therefore, a subroutine called, "Update" can be called if you have changed a complex data structure like a multi-dimensional array. During startup, only the Network Value variables whose value changed since the last synchronization are obtained.

Note: If using a multi-dimensional array with NetworkValues, you should note that the array must be dynamically allocated, rather than static.  Also; you can store dictionaries, but you must use NetworkValues\Update to update them.

The values for Network Value variables are stored in a subdirectory named, "NetworkValues" within your application's directory. The name and format of these files is identical to that of the Retained variables (see Retained Variables); however, the extension for NetworkValues files is ".NV", whereas the extension for the Retained variable files is ".VAL".

Note: It is not recommended that you employ the Network Values service for tag values, or other constantly changing values (e.g. mouse position), as the memory cost will be in the vicinity of .5 to 1.5 K per Network Value variable. A better use for the Network Values service is for updates to other services.

Topics in this section:

Network Value Service Subroutines and Modules

NetworkValues\Register

NetworkValues\Update

NetworkValues\MonitorX

NetworkValues\GetValue

NetworkValues\SetValue

NetworkValues\TestValue

Network Values Service Scheme