Hi,
I am working on creating custom filtering column for RadGrid, my code is largely based on :
http://demos.telerik.com/aspnet-ajax/controls/examples/integration/gridandcombo/defaultcs.aspx?product=grid
But I would like to have a clear filter button attached to each column, and if the button is clicked it will only clear one column instead of all columns. Here is my overrided function
What should I do inside button_Click handler?
TIA
I am working on creating custom filtering column for RadGrid, my code is largely based on :
http://demos.telerik.com/aspnet-ajax/controls/examples/integration/gridandcombo/defaultcs.aspx?product=grid
But I would like to have a clear filter button attached to each column, and if the button is clicked it will only clear one column instead of all columns. Here is my overrided function
protected
override
void
SetupFilterControls(TableCell cell)
{
base
.SetupFilterControls(cell);
cell.Controls.RemoveAt(0);
RadComboBox combo =
new
RadComboBox();
combo.ID = (
"RadComboBox1"
+
this
.UniqueName);
combo.ShowToggleImage =
false
;
//combo.Skin = "Office2007";
combo.EnableLoadOnDemand =
true
;
combo.AutoPostBack =
true
;
combo.MarkFirstMatch =
true
;
combo.Height = Unit.Pixel(100);
combo.ItemsRequested +=
this
.list_ItemsRequested;
combo.SelectedIndexChanged +=
this
.list_SelectedIndexChanged;
cell.Controls.AddAt(0, combo);
ImageButton button =
new
ImageButton();
button.ImageUrl =
"~/images/delete.gif"
;
button.Click +=
this
.button_Click;
button.CssClass =
"ClearButton"
;
cell.Controls.AddAt(1, button);
cell.Controls.RemoveAt(2);
}
TIA