Appendix: Built-in Scripting Language Examples SetTagDisplayUnit Sets the DisplayUnit , UnitDiv , and UnitAdd properties on a specific tag. Syntax SetTagDisplayUnit( strTagName , strDisplayUnit , numDiv , numAdd ) strTagName The name of the specific tag on which the DisplayUnit , UnitDiv and UnitAdd tag fields will be set. Note: If this parameter is given a tag, then that tag should contain the name of the tag on which the tag fields will be set. strDisplayUnit The new value for the DisplayUnit tag field. numDiv numAdd The new value for the UnitDiv tag field. The new value for the UnitAdd tag field.
Returned value Examples InduSoft Web Studio Page 545 Tag Name Expression Tag SetDisplayUnit( "C", "F", 0.555556, 32 ) // For all tags and object values with a Unit of "C", the DisplayUnit tag field is set to "F", the UnitDiv tag field is set to 0.555556, and the UnitAdd tag field is set to 32. Function Group Execution Windows Embedded Thin Client SetTagDisplay UnGiratphic Synchronous Supported Supported Supported 0 Success. -1 Wrong number of parameters. -2 Specified tag doesn't exist. -3 numDiv parameter is invalid (equal to 0).
Tag Name Expression Tag SetTagDisplayUnit( "TagTemp", "F", 0.555556, 32 ) // For the tag "TagTemp", the DisplayUnit tag field is set to "F", the UnitDiv tag field is set to 0.555556, and the UnitAdd tag field is set to 32.