i have telerik radgrid binding with a grid template column with the visibility of the delete icon decided by calling the code behind method ISDeleteVisible with variable from the correponding column is being passed as parameter but when i load the page it says server tag is not well formed error.
<telerik:GridTemplateColumn AllowFiltering="false" UniqueName="Options">
<ItemTemplate>
<asp:ImageButton ID="imgDelete" runat="server" CommandName="cmdDelete" ToolTip="Delete"
Visible="<%# ISDeleteVisible(Eval("AgencyType") %>" CommandArgument="Container.DataItemIndex"
CausesValidation="False" ImageUrl="<%$ Resources:WebResource, deleteIcon %>"
OnClientClick="javascript:return confirm('Are you sure you want to delete?');" />
</ItemTemplate>
<ItemStyle Width="100px" />
</telerik:GridTemplateColumn>
in the code behind i have the code behind method as
protected bool ISDeleteVisible(string AgencyType)
{
if(AgencyType=="HouseHoldAgency")
ISDELETE = true;
else
ISDELETE = false;
return ISDELETE;
}