Form Elements in XMLGrid
I need a way to call events from a Grid that is loaded from a XML doc. Ideally I'd have a radio button as the first column which has triggers an onclick event, however the XML doc is just the data and therefore all the cells are just data. Is there anyway to include a radio button for each row as it is rendered?
Thanks in advance.
Nic
April 28,
Hi Nic,
Try coding the HTML elements in your XML data. Here's an example of some XML with an onclick event handler on a radio button in the first column.
<row>
<col><input type="radio" name="selectedReferral" value="195684" checked onclick="document.forms[1].action='/afs/TaskManagementSummary.do?subAction=Select&updateClient=true&referralNumber=195684';form.submit();" ></col>
<col tooltip="JOHNSON,YOLANDA NMN">JOHNSON,YOLANDA NMN</col>
<col tooltip=""></col>
<col tooltip="05/02/2005 14:29:00">05/02/2005<br>14:29:00</col>
</row>
Note that the HTML is encoded using HtmlEncoder.encode on the text just before each COL tag is written to the page.
Hope that helps.
Craig
May 2,