PML Customisation
User Guide
Gadget Set
: Numeric Input Gadget
Numeric Input Gadget
The NUMERICINPUT gadget allows numeric input within a specified range, with given granularity. It has Up/Down arrow icons which control incrementing and decrementing the displayed value by the specified increment, within the range. The tag text is always displayed.
Additionally it is possible to type in the required value, which is adjusted to the nearest valid value in the range. The default initial value is the minimum value of the range and the maximum value is adjusted so that the range is an integral number of steps.
It is not possible to provide user formatting of the values displayed by the gadget.
It has the following properties and methods:
val
is REAL -
value of the numeric input.
range
is array of REAL -
a real array with members Start, End and step (>0).
ndp
is REAL -
(read only) the number of decimal places. If zero then all values will be integer.
editable
is BOOLEAN -
enable/disable ability to edit the displayed value.
modified
is BOOLEAN -
enable/disable modified events.
setRange
(!range is array of REAL, !ndp is REAL)
The NumericInput gadget supports SELECT and MODIFIED events, and you may provide a callback method to service these events.
Note:
Often no callback is required, and the numeric input value is merely read and used by other gadgets of the form.
A SELECT event is raised whenever you click ENTER while the numeric input display field has focus. Typically this happens after you has typed in a required value, but will also apply if you enter the field after modifying the values using the up/down arrows. The callback can be a simple or an Open callback.
A MODIFIED event is raised for each modification of the displayed value using the up/down arrows. Modified events are only reported if they are enabled and you have provided an Open callback, as this allows differentiation from the SELECT events. The default state is modified events disabled.
1974 to current year.
AVEVA Solutions Limited and its subsidiaries. All rights reserved.