Object PmMap (Object with named values)

In this object it is possible to add and use named values (i.e. the dynamic properties).

At the start (after being created by the Pm.CreatePmMap method) the object is empty and contains only built-in methods starting with map (e.g. mapLoadFromString).

Properties and methods:
Dynamic propertiesDynamic properties added by designer in the script. The names must not contain empty spaces, special characters, diacritics, must not begin with number or map characters.
mapGetValueAt Returns the value of selected object property
mapSetValueAt Sets the value of selected object property
mapLoadFromString Create properties with defined values in the object
mapSaveToString Saves the content of the object into string
mapGetPropNames Returns array containing names of all dynamic properties
- The object can be created by the method Pm.CreatePmMap.
- This object is functional also for Web Panels. It is not functional in InternetExplorer8 and lower.
- The object can be used in both VBScript and JavaScript languages.
Create property and set value:

In this object (contrary to other PROMOTIC objects), it is possible to create new properties with given name and value. New property is created by first write. For example (Example for JavaScript language): = 3.14;
In the oMap object, there is a new property "xyz" containing the value 3.14. Assigning new value to this property only changes the value of this property.

Properties in this object can also be created or set by the mapLoadFromString or mapSetValueAt method.

Caution: In WEB panel that is written inVBScript language it is not possible to create property just by assigning the value. In such case it is possible to use the mapSetValueAt method.

Read property value:
var val =;

Poperty value in this object can also by read by the mapGetValueAt method.

Comparison of objects used for data storage:

The following object types can be used for holding values (of any data type). Each of these objects has certain advantages and the choice depends on the desired usage.

PmArray: This object contains values that are accessible by index in the array - it is possible to read any value at any time. Reading and setting values is very fast, but adding is slow.

This object is functional only for JavaScript language. For the VBScript language the array is represented by Array data type.

PmList: This object contains a list of values. The values can be accessed only from the beginning or from the end of the list. Reading, adding amd removing values from beginning or end of the list is fast, but values "inside" the list cannot be accessed.

The object is designed for processing data as in "container" (stack, LIFO) or "queue" (pipe, FIFO).

PmMap: This object contains values that are addressed by name (text identifier). Value names represent object properties. The advanatege is the "clarity" of usage in the script code. The disadvantage is the inability to access the values in cycle by index.
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice