Internal Web API

list

Other API in Package

Web

User

Internal Tunnel

Tunnel

list tag

Allows iteration over the DataRecord objects of the DataList identified by the name attribute. Supported in documents. It is also possible to define a list based on string input using "list" attribute. If list attribute is used, columns are referenced by 'col0', 'col1', ... 'col[n]'.

Tag Attributes
Attribute Notes
name Required
id Required
odd
even
toggle
list
query
row-delim required if list is used
col-delim required if list is used

Sample:

<table>

<c:list name="items" id="item" odd="#c0c0c0" even="#ffffff" toggle="bg">
    <tr style="background-color:${bg}">
        <td>${item.getValue(0)}</td>
        <td>${item.getValue(1)}</td>
        <td>${item.getValue(2)}</td>
        <td>${item.getValue(3)}</td>
    </tr>
</c:list>

</table>


<div>
    <c:list name="attachments" id="att">
        <c:set name="pipe" true="" false="|" test="${attidx==0}"/>
        ${pipe} <c:window attachment="${att.getDataValue('id')}">${att.getDataValue("description")}</c:window>
    </c:list>
</div>

<table border="1">
    <c:list name="products" id="item">
        <tr>
            <td>${itemidi}</td>
            <td><c:item id="item"><c:fragment name="product"/></c:item></td>
            <td><c:item id="item"><c:fragment name="product" test="${itemidc!=null}"/></c:item></td>
            <td><c:item id="item"><c:fragment name="product" test="${itemidc!=null}"/></c:item></td>
        </tr>
    </c:list>
</table>

"product" fragment:
<div>
<b>${item.get('name')}</b><br/>
<img src="../images/${itemidc}.jpg"/>
</div>

String based list:
<c:list name="myList" id="item" list="a,b,c;d,f,g" row-delim=";" col-delim=",">
    <tr>
        <td>${item.get('col0')}</td>
        <td>${item.get('col1')}</td>
        <td>${item.get('col2')}</td>
    </tr>
</c:list>

String based list with next-line delimiter:
in workflow:
page.setValue("inputString", "line1\nline2");

on page:
<c:list name="myList" id="item" list="${inputString}" row-delim="\n">
        <li>${item.get('col0')}</li>
</c:list>
        
Copyright © 2006 - 2024, ContractPal, Inc. All rights reserved. API Date: Jul 15, 2024 03:42 PM