Promotic

onButtonUp - event of the PmgButtonState object

Description:
The event is triggered on pressing the button on the keyboard or the mouse.
Parameters:
pMe(Object) Reference to the PmgButtonState object where the event rises.
pEvent(Object) Reference to object describing detailed information about the specific event.
pEvent.State - (Long) [for reading] Original button state
pEvent.NextState - (Long) [for read and write] Next button state.
It is preset by the system to the state value opposite to the State state.
By changing this preset value it is possible to suppress toggling the state if it isn't desirable (e.g. the action failed and therefore it isn't desirable to toggle the button state).
Note:
This event is triggered only if the "Control enabled" configurator is checked.

This event is also functional in Web panels. Writing into the pEvent.NextState property is not functional in the Web panel so far.

The button state can be obtained also by means of the State property.
Example:
JavaScriptVBScriptSelect and copy to clipboard

if (pEvent.NextState == 1)
{
// transition to state 1
}
else
{
// transition to state 0
}
PROMOTIC 9.0.24 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r. o.