IBM Books

Reference

DTW_TB_TABLE


AIX HP-UX Linux OS/2 OS/390 OS/400 SCO 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 162. 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 163. 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 The number of parameters passed on a function call either exceeded the maximum number allowed, or was less than the minimum number required by the function.
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>LINKURL
<TH>IMAGEURL
<TR>
<TD><i>link1text</i>
<TD><A HREF="http://www.mycompany.com/link1.html"><b>link1text</b></A>
<TD><IMG SRC="http://www.mycompany.com/images/image1.gif" ALT=""><b>link1text</b>
<TR>
<TD><i>link2text</i>
<TD><A HREF="http://www.mycompany.com/link2.html"><b>link2text</b></A>
<TD><IMG SRC="http://www.mycompany.com/images/image2.gif" ALT=""><b>link2text</b>
<TR>
<TD><i>link3text</i>
<TD><A HREF="http://www.mycompany.com/link3.html"><b>link3text</b></A>
<TD><IMG SRC="http://www.mycompany.com/images/image3.gif" ALT=""><b>link3text</b>
</TABLE>


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