object can offer its image in the Web browser (Chrome
...) in the form of dynamic HTML pages
. These dynamic pages are created automatically
in the development environment and they are stored in the Application.pra
So as the PmaPanel
object would offer its image to Web server, it is necessary to:
- and to fill in all other configurators on this tab correctly.
The client requiring data from this Web component is of the PmWebClient
type from the licence point of view.
Since version Pm9.0.0
all Web panels in PROMOTIC are designed only for Web browsers supporting standard HTML5
technology. It means for Chrome
etc. The InternetExplorer
is supported only since version 11.
Since the version Pm8.2.0
the HTML pages generated by the system were transformed to standard HTML5
technologies so these can be displayed in alternative browsers (Chrome
...) including their mobile versions.
Up to the PROMOTIC version Pm8.2
the HTML pages generated by the system were designed only for InternetExplorer
Web panels basic principle:
- Pmg objects are compiled into dynamic HTML form (using so-called Alax technology).
- If the client is opening panel, then the compiled dynamic HTML panel page is loaded from server (i.e. from the PROMOTIC application). Panel refreshing (see the "Refresh period of the Web panel [s]
" configurator) is called automatically and is based on periodically loading XML panel data, which are much smaller then the whole HTML page. For example if the panel is connected by data binding to 10 variables, then only 10 current values are periodically transferred. The server load is therefore minimal.
- The scripts
in events of Pmg
objects are running on the client side
(i.e. in the Web browser). Some restrictions are based on this fact and these are described below.
The main restriction is that it is unable to access directly in the script to other objects in the tree of Pma
objects, for example access for values in the PmaData
object (this limitation is valid for scripts - not for example in the "PP - Data binding to Pma object property
" data binding - it can use references to other objects).
This limitation can be solved, by calling for example the panel method (i.e. in the event of the Pmg
. This calling the "XXX
" method makes the client send XML command to server and so the method is called on the server. In this panel method the script can be present, accessing other objects in the tree of Pma
objects. For additional info see more.
Here is a list of limitations that are put on panels that have to be offered to Web server in the form of a HTML page.
- Limitations for writing of algorithm (scripts)
- It is not possible to use the reference to other Pma objects
in the tree of Pma
objects (e.g. to use pMe
). If writing to other object in the Web panel
is needed it, then is possible to do so:
- The global Pm object:
Many methods are functional on the Web but some are not. The description of each method of this object provides the information of Web functionality.
- Limitations for Pmg objects:
" configurator is not relevant.
" configurator with "Selection and edit"
setting is not functional for the Web so far.
This object is not functional on the Web because all modern Web browsers no longer support ActiveX
technology due to security reasons.
This object is obsolete and is not functional on the Web.
- Limitations for calling the designer's method of the PmaPanel object
See Designer's methods in the PmaPanel
Called methods can have parameters and an output value (pResult
- simple data types (e.g. Integer, String, etc.)
- 1-dimensional array defined e.g. Dim arr(20)
- 2-dimensional array defined e.g. Dim arr(10,20)
- there must not be other arrays in the array items
Notes and directions:
Another algorithm for local panel and for Web panel
A panel (created in the PmaPanel
object) can be opened directly in runtime of the application (local panel) or in the Web browser (Web panel). If in such panel calling an algorithm is needed (for example after pressing the button), which has to do something different in local panel than in the Web panel
, then it is recommended to use the PmgRoot.ClientType property
. The value of this property specifies whether the panel is opened in the application or in the Web browser. Examples see description of the ClientType
When developing a Web panel, it is necessary to understand, that, multiple clients can see it simultaneously. So it is a bad idea for example to create one panel (one PmaPanel
object) able to display multiple devices according to a variable set in the application. In such case the clients would be rewriting this global variable mutually and see incorrect values as a consequence. If one panel displaying various data is needed, then the best way to do so, is: