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 HTML radio button input tags from a Net.Data table.
Format
@DTW_TB_INPUT_RADIO(table, prompt, namecol, valuecol, rows, checkedrows)
@DTW_TB_INPUT_RADIO(table, prompt, namecol, valuecol, rows)
@DTW_TB_INPUT_RADIO(table, prompt, namecol, valuecol)
Parameters
Table 142. DTW_TB_INPUT_RADIO Parameters
Data Type | Parameter | Use | Description |
---|---|---|---|
table | table | IN | The macro table variable to display as radio button input tags. |
string | prompt | IN | The column number in table or a string containing the text to display next to the radio button. Required parameter, but can contain a null ("") value. When prompt is null, uses the value of valuecol. |
string | namecol | IN | The column number in table or a string containing the input field names. |
integer | valuecol | IN | The column number in table that contains the input field values. |
string | rows | IN | The list of rows in table from which to generate the input fields. The default is to use all rows. |
integer | checkedrows | IN | A row number in table to display the corresponding radio button as checked. Only one value is allowed. |
Return Codes
Table 143. DTW_TB_INPUT_RADIO 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. |
1002 | An input parameter contained a string value which consisted of the null-terminating character. |
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 for three radio button input tags
@DTW_TB_INPUT_RADIO(Mytable,"3","Radio4","4","2 3 4","4")
Results:
<input type="radio" name="radio4" value="link2text" />image2text<br /> <input type="radio" name="radio4" value="link3text" />image3text<br /> <input type="radio" name="radio4" value="link4text" checked />image4text<br />