This is a migrated thread and some comments may be shown as answers.

Filtering problem

4 Answers 90 Views
GridView
This is a migrated thread and some comments may be shown as answers.
OverCoded
Top achievements
Rank 2
OverCoded asked on 06 Oct 2010, 06:50 PM
I have gridview with check boxes that needs a filtering function. The problem with the default filter is that if a user opens the filter dialog an selects an item from the list all of the checked/selected items in the gridview are removed. I thought that I could add the checked items to the filter descriptor just prior to the filter event but it removes everything else from the filter list as well. Does anyone know a way around this problem?
I think what I need is the actual filterdescriptor that is being applied at the time the UI is active. I need to add my filterdescriptor to it or add a columndescriptor.

4 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 11 Oct 2010, 11:31 AM
Hello OverCoded,

Unfortunately, we could not understand what you are trying to achieve.

You have a grid with a boolean column? The user selects either True or False from the distinct values list-box. Then based on what he has selected only the True's or the False's remain? If that is so -- this is by design. These are called distinct values and they work like this.

Anyway, instead of guessing about your task and shooting in the dark, could you please send us a small sample project and describe in great detail what exactly are you trying to achieve. We will then see whether it is possible or not.

Thanks in advance. We are looking forward to hearing from you.

Best wishes,
Ross
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
0
OverCoded
Top achievements
Rank 2
answered on 11 Oct 2010, 01:26 PM
This is a team project involving programmers in other locations of the country. I do not have the time to develop a sample project. It is really quite simple. If I have grid with part numbers (thousands) that can be selected by checking a checkbox I need to be able to retain the checked items even when the funnel filter control is activated. Currently, if a user makes several selections by checking their boxes and then using the filter to look for another item/part the checked items are lost because they are filtered out. I want to keep the checked items/parts within the filter scope pragmatically so I don't loose the checked items.
0
Rossen Hristov
Telerik team
answered on 11 Oct 2010, 02:11 PM
Hi OverCoded,

I am afraid that this can not be done unless you develop your own very complex custom filtering control.

Even if you do that -- I am not sure how you can keep items that are filtered out to be part of the collection. This just does not make sense and is not possible out-of-the-box.

Anyway, if you decide to try to develop a custom filtering control, then this blog is the tutorial for you.

I hope this helps.

Best wishes,
Ross
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
0
OverCoded
Top achievements
Rank 2
answered on 11 Oct 2010, 04:30 PM
I will find another approach to the problem. However, I would have to disagree with you that it does not make sense. It is a matter of usage. If I have a list of items to pick from that is several thousand I would like to offer the user a quick way to locate items to check as apposed to having to scroll through all of them.
At this point the grids only function would be to provide a view. However, checkboxes are provided, I'm not sure why because you cannot maintain state for any item that has been checked once you use the filter. So, I can conclude that a checkbox column is not really going to work within a grid that also has filtering unless the filtering has been done first. Unfortunately that is nothing more than a subgrid with checkboxes as well. The user has to scroll through that entire list to locate all the items to filter. Once they have done that, what is the point of having checkboxes on the grid?
If the the filtering only hid the items being filtered out from the user instead of removing them, the checked/selected items could maintain state--checked but not visible until clear filter is selected.
Tags
GridView
Asked by
OverCoded
Top achievements
Rank 2
Answers by
Rossen Hristov
Telerik team
OverCoded
Top achievements
Rank 2
Share this question
or