Promotic

GetChildByIndex - method of the PmgObject object

Description:
Returns the nested Pmg object defined by order.
Syntax:
Object GetChildByIndex(Long nIndex)
Parameters:
nIndex(Long) the order (index) of the nested Pmg object (zero-based index).
Note:
It is used mainly for multiple modifications of nested Pmg objects of certain type.
For Pma object the GetOwnedByIndex method can be used for the same purpose.

This method is also functional in Web panels.
Example:
JavaScriptVBScriptSelect and copy to clipboard

var iItem, oObject;
var oRoot = pMe.Root;
var nChildCount = oRoot.GetChildCount();
for (iItem = 0; iItem < nChildCount; iItem++)
{
oObject = oRoot.GetChildByIndex(iItem);
Pm.Debug(oObject.Name);
}
PROMOTIC 9.0.27 SCADA system documentation MICROSYS, spol. s r.o.

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