Hi Mira,
Thank you for your sample, it works. However, I got a little issue with it. I am using the Filter to filter the RadGrid, after I select values from dropdownlist and hit apply buttonto filter the grid and then come back to the Filter, I cannot close it by clicking the cross icon of that particular dropdownEditor, it just keep showing up. I can close it if I don't hit the apply button. Below is my code besides the CustomEditor class which is untouched from your sample:
protected void RadFilter2_OnLoad(object sender, EventArgs e)
{
RadFilterDropDownEditor _filterEditor = new RadFilterDropDownEditor();
RadFilter2.FieldEditors.RemoveAt(0);
RadFilter2.FieldEditors.Insert(0, _filterEditor);
List<AccountCollection> _list = new List<AccountCollection>();
_list.Add(new AccountCollection("Stage1", "0"));
_list.Add(new AccountCollection("Stage2", "1"));
_list.Add(new AccountCollection("Stage3", "2"));
_filterEditor.DataTextField = "Name";
_filterEditor.DataValueField = "Value";
_filterEditor.FieldName = "Stage";
_filterEditor.DataSource = _list;
}
protected void RadFilter2_FieldEditorCreating(object sender, RadFilterFieldEditorCreatingEventArgs e)
{
e.Editor =
new RadFilterDropDownEditor();
}
protected void ApplyButton_Click(object sender, EventArgs e)
{
RadFilter2.FireApplyCommand();
}
and my Filter in aspx page:
I can work around by closing all of them together but i just cannot close that dropdown filter item. I hope i addressed my issue clear enough.
Thank you!