DTW_TB_TABLE

AIX HP-UX Linux OS/2 OS/390 OS/400 PTX SUN Win NT
X X X X X X X X X

Purpose

Generates an HTML table from a Net.Data table.

Format

@DTW_TB_TABLE(table, options, collist, cellstyle, link_u, image_u, url_text, url_style)

@DTW_TB_TABLE(table, options, collist, cellstyle, link_u, image_u, url_text)

@DTW_TB_TABLE(table, options, collist, cellstyle, link_u, image_u)

@DTW_TB_TABLE(table, options, collist, cellstyle, link_u)

@DTW_TB_TABLE(table, options, collist, cellstyle)

@DTW_TB_TABLE(table, options, collist)

@DTW_TB_TABLE(table, options)

@DTW_TB_TABLE(table)

Parameters

Table 164. DTW_TB_TABLE Parameters
Data Type Parameter Use Description
table table IN A macro table variable to display as an HTML table.
string options IN The table attributes inside the TABLE tag. The default is to use no attributes. Valid values include:
  • BORDER
  • CELLSPACING
  • WIDTH
string collist IN The column numbers in table to use in the HTML table. The default is to use all the columns.
string cellstyle IN A list of HTML style elements, such as B and I, to go around text in each TD tag. The default is not to use style tags.
integer link_u IN The column number in table containing URLs used to create HTML links. You must specify the column in collist also. The default is not to generate HTML links.
integer image_u IN The column number in table containing URLs used to create inline images. You must specify the column in collist also. The default is not to generate image tags.
integer url_text IN The column number in table containing text to display for HTML links or inline images. The default is to use the URL itself.
string url_style IN A list of HTML style elements for the text specified in url_text. The default is not to generate style tags.

Return Codes

Table 165. DTW_TB_TABLE Return Codes
Return Code Explanation
-1001 The server could not process a Net.Data request to allocate memory.
1001 An input parameter contained a NULL value.
1003 An incorrect number of parameters were passed on a function call.
1004 A parameter passed on a function call, required to be a Net.Data macro table variable, was of a different variable type.
1005 A parameter passed on a function call, required to be a string variable, was of a different variable type.
1007 A parameter contains a value which is not valid.
1008 A parameter is outside of table bounds.

Examples

Example 1: Generates HTML tags for a table with a border and using B (bold) and I (italics) tags

@DTW_TB_TABLE(Mytable,"BORDER","4 2 1","i","2","1","4","b")

Results:

<table border>
<tr>
<th>TITLE</th>
<th>LINKURL</th>
<th>IMAGEURL</th>
<tr>
<td><i>link1text</i></td>
<td><a href="http://www.mycompany.com/link1.html"><b>link1text</b></a></td>
<td><img src="http://www.mycompany.com/images/image1.gif" alt=""><b>link1text</b></td>
</tr><tr>
<td><i>link2text</i></td>
<td><a href="http://www.mycompany.com/link2.html"><b>link2text</b></a></td>
<td><img src="http://www.mycompany.com/images/image2.gif" alt=""><b>link2text</b></td>
</tr><tr>
<td><i>link3text</i></td>
<td><a href="http://www.mycompany.com/link3.html"><b>link3text</b></a></td>
<td><img src="http://www.mycompany.com/images/image3.gif" alt=""><b>link3text</b></td>
</tr></table>


[ Top of Page | Previous Page | Next Page | Index ]