|
Property "Repeat | For Each" <foreach> |
|
|
This property is used to query the XML nodes for which the container element will be repeated. For example, to repeat a container element for each <item> in <products>;
We should set the "Repeat | For Each" property as "/products/item" If you omit the root tag name MoreMotion Application Studio will assume that it is the value defined with "XML Root Tag Name" property of page element. If not otherwise specified the value is "<root>" by default. /root/products/item
and /products/item
will do the same job. If the root tag in your XML document is different than "root" you can set it using "XML Root Tag Name" property of the page. The Syntax The syntax that is used in definition of this property is nothing but XSL. <xsl:for-each select="the value of property is put here..."> ... </xsl:for-each>
Therefore its capabilities is only limited with XSL. Examples: /products/item /products/item[price > 1000] //item[id = 'P0017']
See Also Repeat Property Parameters For Inner Repeats Property
|