Update cookies preferences
Promotic

Conversion of panels from VBScript technology to JavaScript

The main purpose of this chapter is to show you how to transfer your panels to JavaScript language. Common mistake warnings are included, methods described and debugging explained.

Basic principles of Web panel creation are described in the Web panel.
The individual differences between the syntaxe of both languages are briefly described in chapter Comparison of the VBScript and JavaScript languages.
JavaScript is implemented as "case sensitive", i.e. it is necessary to observe the usage of capital letters in method names, statements and keywords. Statements it is necessary to separate by semicolon character ;

The first step of panel debugging is eliminating the errors reported by INFO system during local application runtime. While testing the panel on a Web client (Chrome, Firefox, ...) the combination of keys Ctrl+Shift+Alt+space can be used. This debugging tool can be used to detect additional errors that would not show in the local application.

Common script errors that appear repeatedly:
- Missuse of capital letters in method names, statements and keywords.
- Statements not separated by semicolon.


Other errors that are common in Web panels enabled in the "Enable as Web component" configurator are:
- It is not possible to access Pma objects outside of this panel. See Limitations for writing of algorithm (scripts).
- Reading or writing into the cell properties of the PmgWTable object is replaced by methods (e.g. the CellText property replace by the SetCellText method, etc.).
PROMOTIC 9.0.31 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
Navigation:
 
 
- Conversion of panels from VBScript technology to JavaScript
 
 
© MICROSYS, spol. s r.o.