Preconfiguration "PmExpr - mathematical expression"
Creation and evaluation of mathematical JavaScript expression by the
PmExpr object.
This preconfiguration can be activated when creating a new object (e.g. by
"New object ..." in the context menu of the object or by pressing the
Insert key after selecting the object).
This preconfiguration is included in the
"/ Panels (PmaPanel) / Others examples" group.
This preconfiguration can be created in the
PmaFolder,
PmaRoot or
PmaPrototype object.
- The preconfiguration is created including the panel (object of the
PmaPanel type) is functional also as
Web panel.
This preconfiguration allows to test and evaluate user created mathematical expression (
PmExpr) in the
JavaScript language syntax. There are predefined variables that can be used in the expression.
In this preconfiguration, there are static predefined variables in the
"ListVariables" method of the created
PmaFolder object. The
"ResultExpr" method of this object then returns the evaluated expression that was previously passed to it in its parameter.
The testing panel
PanelMain demonstrates the possible entries of mathematical expression in three examples. On the right side there is the evaluated value. On the bottom there are the real values of variables that can be used in the expression. The objects used as expression entries or for displaying the results can be edited locally and their modification is immediately resulting in change of the resulting evaluated value.
From panel
PanelMain it is possible to open the "
PanelExpr" panel by the button. It can be used as simple mathematical expression editor where it is possible to use the buttons from the left to right in order to create desired expression. It is also possible to edit it also locally on spot.
These configurators can be set before the preconfiguration is created:
The name of created object | Name of the object created in the Pma object tree.
The maximum name length is 30 characters.
This is a system name, so it must contain only alphanumeric and must not contain any diacritics (i.e. national dependent characters), empty string, spaces and first character must not be a number.
Default: "PmExpr" |
|
Enable as Web component | Specifies whether this object has to be registered as a Web server component
After the preconfiguration is created, the "PmaPanel > Web server > Enable as Web component" configurator will be set to this value. |
PmaWeb object | Path in the Pma object tree to the object PmaWeb, PmaWebFolder or PmaWebLang where the registration is carried out.
Macro expression can be used for input (it is evaluated after the application is launched).
After the preconfiguration is created, the "PmaPanel > Web server > PmaWeb object" configurator will be set to this value. |
---|