Hi,
If I want the filter field dropdown to be populated with "PersonId", "PersonName", "PersonCity", should I create three RadFilterTextFieldEditor objects and add them to the FieldEditors collection?
I stored the field names in a database. I get the data from the database and create the editors in the Page_Load.
if (!IsPostBack)
{
List<FilterField> fields = db.GetData();
foreach (FilterField field in fields)
{
RadFilterTextFieldEditor editor = new RadFilterTextFieldEditor();
editor.FieldName = field.Name;
RadFilter1.FieldEditors.Add(editor);
}
}
It works when the page is first loaded, however, I got an error in any following postback.
Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
I appreciate it very much if you can help.
If I want the filter field dropdown to be populated with "PersonId", "PersonName", "PersonCity", should I create three RadFilterTextFieldEditor objects and add them to the FieldEditors collection?
I stored the field names in a database. I get the data from the database and create the editors in the Page_Load.
if (!IsPostBack)
{
List<FilterField> fields = db.GetData();
foreach (FilterField field in fields)
{
RadFilterTextFieldEditor editor = new RadFilterTextFieldEditor();
editor.FieldName = field.Name;
RadFilter1.FieldEditors.Add(editor);
}
}
It works when the page is first loaded, however, I got an error in any following postback.
Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
I appreciate it very much if you can help.