Bookshelf Home | Contents | Index | Search | PDF |
Siebel Tools Reference > Physical User Interface Layer > Understanding Siebel Tags >
Iterators
Iterator tags specify the number of times the tag should iterate its contents. For example, the swe:for-each tag allows you to reduce the size of the template files where the same HTML and Siebel tags are used with controls or page items with different values for the id parameter:
<swe:for-each
count="x" iteratorName="yyyy" startValue="z"/>Other iterator tags include
swe:for-each-row, swe:for-each-child, swe:for-each-node, swe:for-each-indent, swe:for-each-value.
The attributes of the swe:for-each tag are as follows:
- count. Specifies the number of times the tag should iterate its contents.
- startValue. The value that should be assigned to the iterator at the start of the iteration. The tag will start the iteration by assigning this value to the iterator, and will increment it by one for each iteration.
- iteratorName. The name of the iterator. This name can be used to get the value of the iterator during the iteration using the syntax swe:iteratorName.
In the section enclosed by the
swe:for-each
tag, references to the current value of the iterator is through the name specified in the iteratorName attribute. For example, if you set the value of the iteratorName to "CurrentID," then you can get the value of the iterator using the syntaxswe:CurrentID
. You can also reference a value that is an increment over the current value asswe:CurrentID+x
. The fragment below illustrates this usage:<swe:for-each startValue="2301" count="50" iteratorName="currentId">
<swe:control id="swe:currentId">
.
.
</swe:control>
<swe:control id="swe:currentId+100" />
</swe:for-each>
Bookshelf Home | Contents | Index | Search | PDF |
Siebel Tools Reference, Version 7.5, Rev. A Published: 18 April 2003 |