I have a datagrid which uses an TemplateColumn due to formatting restrictions. Inside this I wish to have
an image link that when clicked fires a sub() and passes in the particular MyID for that record. Usually
I can achieve this with the <asp:EditCommandColumn> and setting the OnEditCommand of the DataGrid but
I cannot here as I need the particular image link where it is. Can anyone suggest how I might accomplish
this?
<asp
ataGrid id="dgDataGrid" DataKeyField="MyID">
<asp:TemplateColumn>
<ItemTemplate>
<table>
...
<tr>
<td>
<a href="y.aspx" id="lnkClickMe" onserverclick="lnkClickMe_Click"><img src="images/x.gif" /> click me</a>
</td>
</tr>
</table>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp
ataGrid>
an image link that when clicked fires a sub() and passes in the particular MyID for that record. Usually
I can achieve this with the <asp:EditCommandColumn> and setting the OnEditCommand of the DataGrid but
I cannot here as I need the particular image link where it is. Can anyone suggest how I might accomplish
this?
<asp
<asp:TemplateColumn>
<ItemTemplate>
<table>
...
<tr>
<td>
<a href="y.aspx" id="lnkClickMe" onserverclick="lnkClickMe_Click"><img src="images/x.gif" /> click me</a>
</td>
</tr>
</table>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp