Value Display

Top  Previous  Next

clip0012 The value control allows you to display a data point value in numeric or, possibly, text form.  Its very similar to the static text control, except that what is displayed is determined by an expression.  An expression is basically a formula, the result, of which, is displayed by the control.  Expressions can be as simple as a tag name, or even just a number, or they can be more complicated, combining multiple tags, various formula and mathematical operators and numbers.  They use Javascript syntax.  For example: Math.sin(tag * 3) / othertag

The details of expressions are discussed later.  For now, if you just want to display a value coming in from a data source, click on the down arrow to the right of the edit box and select the data source and the tag you wish to view.

Caption: this is a text label that is displayed in front of the value.

Expression: a formula in Javascript syntax, the result of which is displayed by the control.

Units: a text label that is displayed after the value.

Precision: determines how many digits past the decimal place are displayed.  This only applies if the result of the expression is a number and not a string.

Property names for script access (intermediate):

you can access the properties of this control as described in the script section.  Here are the properties for this control:

caption
units
precision
expression: this is a string representing the expression
mainStyle: the style used.  Please see the section on scripted changing of styles for more information.