Hi
I'm using a Radgrid, fairly simple implementation:
I'm having an issue with the filter options, I have enabled column filtering and this is working fine. I want to limit the number of filter options available. I followed this guide: http://www.telerik.com/help/aspnet-ajax/grid-reducing-filtermenu-options.html
I created an Init handler:
However this isn't working, if I attach a breakpoint the code isn't being hit.
Any advice?
Thanks
I'm using a Radgrid, fairly simple implementation:
<telerik:RadGrid ID="approval" runat="server" AutoGenerateColumns="False" CellSpacing="0" GridLines="None" AllowFilteringByColumn="true" onneeddatasource="approval_NeedDataSource" OnItemCommand="approval_ItemCommand" OnInit="approval_Init" ><MasterTableView allowpaging="True" datakeynames="Id" AllowSorting="true" name="claims" commanditemdisplay="Bottom" AllowFilteringByColumn="true">I'm having an issue with the filter options, I have enabled column filtering and this is working fine. I want to limit the number of filter options available. I followed this guide: http://www.telerik.com/help/aspnet-ajax/grid-reducing-filtermenu-options.html
I created an Init handler:
protected void approval_Init(object sender, EventArgs e){ GridFilterMenu menu = approval.FilterMenu; int i = 0; while (i < menu.Items.Count) { if (menu.Items[i].Text == "NoFilter" || menu.Items[i].Text == "Contains" || menu.Items[i].Text == "DoesNotContain" || menu.Items[i].Text == "EqualTo" || menu.Items[i].Text == "GreaterThan" || menu.Items[i].Text == "LessThan") { i++; } else { menu.Items.RemoveAt(i); } }}However this isn't working, if I attach a breakpoint the code isn't being hit.
Any advice?
Thanks