Grid Column Example
This example adds a combo box to the Department column in a list of employees. It assumes an employee list called #EMPLIST containing a #DEPTMENT column and a department list called #DEPTS containing #DEPTMENT and #DEPTDESC.
1. Add a grid to the Webroutine design and set its EMPLIST.
property to2. Modify the
property and select the Customize Column option for the column.3. Drag a combo box weblet onto the first non-header cell of the
column.4. Set the DEPTS.
property of the dropdown to5. Set the DEPTMENT and the property to DEPTDESC. Your grid should be looking something like this:
property to
Notice that the
Notice, also, that the property is set to $tsml_col_mode. This is a special XSLT variable used inside the grid to indicate the display mode defined in the DEF_LIST.
Now an
action will be added to the combo box to execute a Webroutine when a value is changed. The Webroutine, UpdateDepartment, takes two inputs: and .6. Set the UpdateDepartment.
property of the combo box to7. Set the DEPTMENT. This tells the combo box to submit the selected value of the column (in the list).
property of the combo box to8. Set the EMPNO and set the property to ../lxml:column[@name='EMPNO']. As this is an XPath expression you must use the XPath entry area at the bottom of the details tab to enter the value. This tells the combo box to get the value of the EMPNO column of the grid and submit it in a field called EMPNO.
property of the combo box to