Filtering the Gridview with ObjectContainerDataSource

Topics: Web Client Software Factory
Jun 7, 2007 at 4:56 PM
Is there a way to filter out a gridview when you use the ObjectContainerDataSource as your data source? I know this can be done with other types of data sources such as sqldatasource and objectdatasource, but I couldn't find a filter expression for ObjectContainerDataSource. Is it possible?
Jun 7, 2007 at 10:56 PM
Edited Jun 7, 2007 at 10:57 PM
I believe its not possible, u should filter the objectcollection before u give it to the ObjectContainerDataSource.


Jun 8, 2007 at 5:13 AM
There is no built in, declarative mechanism for filtering, at least none that I am aware of. We have considered investing time in extending the ObjectContainerDataSource to handle such a situation, but I have not had time to work on it. I already hacked it up a little a few months ago to handle hierarchical objects and nullable types (we use the Service Factory's data access mapper which uses C#'s nullable type system). I actually think the ObjectContainerDataSource is a clever component, but it needs a little more work to come up to the level of the out of the box data sources.