Remove selection filters

6 posts, 0 answers
  1. Andrew
    Andrew avatar
    68 posts
    Member since:
    Jul 2010

    Posted 17 Oct 2010 Link to this post

    I would like to leave the main filtering but to remove the list of items type of filter.  How do you turn that off?

    By the way I am working on the c# code necessary to pass the filters to devforce so they are executed on the server.  If someone has already done this, please share.
  2. Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 20 Oct 2010 Link to this post

    Hello Andrew,

    You can control the filtering through setting the following boolean properties in your columns ShowDistinctFilters controls the top part of the FilteringControl, and ShowFieldFilters that controls the visibility of the bottom part.
    Hope this helps.

    Kind regards,
    Vanya Pavlova
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Andrew
    Andrew avatar
    68 posts
    Member since:
    Jul 2010

    Posted 20 Oct 2010 Link to this post

    It worked, I was able to ditch the top part of the filter.  But unfortunately for a checkbox column I was unable to get a filter to appear.  Why can I not filter a checkbox column, it should be simple, checked, unchecked, or null should always be options, or at least checked or unchecked.  This is a serious flaw since the binary fields exist because I need them as filters.

    Also you need to add these options to the grid definition so that when columns are autogenerated they can also be set, and also so you can set the defaults and not have to set each column.  The goal is always no repetitive coding, and this is really repetitive.

    I need a solution to the filtering on the checkbox column ASAP please.
  4. Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 22 Oct 2010 Link to this post

    Hi Andrew,

    These properties are designed to work it GridViewColumns, and there is no way to set this property once and when you auto generate its columns to get different filters in each column. Even if you handle AutoGeneratingColumn event of the RadGridView you should check what column type is generated and set the corresponding property. These properties should be set either in xaml or in code. Considering your second question about GridViewCheckBoxColumn you do not need to set ShowDistinctFilters to False, because in this way you will get only the Filter and Clear Filter buttons. Actually you do not need to set anything on that column type and you will get the default behaviour.

    I have prepared an example for you that uses the mentioned properties.

    Best wishes,
    Vanya Pavlova
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. Andrew
    Andrew avatar
    68 posts
    Member since:
    Jul 2010

    Posted 26 Oct 2010 Link to this post

    My only issue is that when you have a checkbox column and all the columns in memory are true or false, then only those filter options appear.  i.e. True only or False only, not both.  You need to show both regardless of what you think is in the data, since filters are sometimes passed to the database for execution.

  6. Scott
    Scott avatar
    3 posts
    Member since:
    Feb 2011

    Posted 19 Sep 2011 Link to this post

    Hi Vanya -
    Turning off the top part of the filter is something I asked about in another similar thread.  Thanks for the answer.
Back to Top