Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > General Discussions > remove Filter Items
RadControls for ASP.NET are no longer supported (see this page for reference). In case you have inquiries about the Telerik ASP.NET AJAX controls, post them in the pertinent ASP.NET AJAX forums.

Not answered remove Filter Items

Feed from this thread
  • rik butcher avatar

    Posted on May 27, 2011 (permalink)

    guys, i've looked for quite some time & nothing i've found is working. it may be how i'm applying it or it may not be possible to be done.
    at any rate i'm building a radFilter Dynamically from an .xml file. - i  look at the dataType and add the editor. works perfectly.
    what i'd like to do is remove selection options such as: "GreaterThanOrEqualTo" &  i read on one of the forums where i just simply have to tap into Localization and give that option an empty string.

    example:  DynReportRadFilter.Localization.FilterFunctionGreaterThanOrEqualTo =

     

    "";

    my problem is no matter where i call this from, the option is still there. i've put it in "prerender", when each editor is created, and on and on & nothing seems to work. is this the wrong approach for what i want to do? since i'm creating these dynamically on page_load, is there perhaps some other method i need to do?  
    thanks for any help
    rik 

     

     

     

     

    protected void readXMLSearch(string xmlFile)

     

     

    {

     

     

     

    string myPath = Server.MapPath("DynReportXml\\" + xmlFile + ".xml");

     

     

     

     

    DataSet ds = new DataSet();

     

     

     

     

    DataTable dt = new DataTable();

     

    try

    {

    ds.ReadXml(myPath);

    dt = ds.Tables[0];

     

     

     

     

    foreach (DataRow aRow in dt.Rows)

     

     

    {

     

     

     

    RadFilterTextFieldEditor editor = new RadFilterTextFieldEditor();

     

     

     

     

    RadFilterDateFieldEditor dateEditor = new RadFilterDateFieldEditor();

     

     

     

     

    string myType = (string)aRow["dataType"];

     

     

     

     

     

    if (myType == "datetime")

     

     

    {

     

    DynReportRadFilter.FieldEditors.Add(dateEditor);

     

    dateEditor.FieldName = (

     

     

    string)aRow["dbColumn"];

     

     

    dateEditor.DisplayName = (

     

     

    string)aRow["display"];

     

     

    }

     

     

     

     

    else

     

     

     

     

     

     

     

     

    {

     

    DynReportRadFilter.FieldEditors.Add(editor);

     

    editor.FieldName = (

     

     

    string)aRow["dbColumn"];

     

     

    editor.DisplayName = (

     

     

    string)aRow["display"];

     

     

    }

     

     

     

    }

     

    }

     

     

     

    catch

     

     

     

     

     

     

     

     

    {

     

    }

     

    }

  • Tsvetina Tsvetina admin's avatar

    Posted on May 28, 2011 (permalink)

    Hello Rik,

    Take a look at the following forum post. It shows how to reduce the filter options with client script only:
    Custom List of Filter Functions

    Greetings,
    Tsvetina
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > General Discussions > remove Filter Items