Hi Jay,
You don't seem to be getting any replies so I thought I would be it another
try.
If you have a look at the DataViewSettings class in the help, it reads
"Represents the default settings for ApplyDefaultSort, DataViewManager,
RowFilter, RowStateFilter, Sort, and Table for DataViews created from the
DataViewManager".
I think the key word here is DEFAULT.
dataSet.DefaultViewManager.DataViewSettings[ dataTable ].RowFilter =
"Category = 'Cat One'";
DataView dataView = dataSet.DefaultViewManager.CreateDataView(dataTable);
// dataView.RowFilter matches the Category = 'Cat One' from above
dataSet.DefaultViewManager.DataViewSettings[ dataTable ].RowFilter =
"Category = 'Cat Two'";
// dataView.RowFilter isn't updated - it's still Category = 'Cat One'
So it seems DataViewSettings[ dataTable ].RowFilter is only read when
creating a new DataView.
Hope this is of some help.
Best Regards,
Phil.
> On Feb 12 I posted a request for some help with the subject "Changing the
> DataViewManager.RowFilter has no effect". I attached some sample code
[quoted text clipped - 5 lines]
>
> Thanks
Jay Pondy - 16 Feb 2005 12:15 GMT
Phil
Thanks for your continued efforts on this one. I don't have my source here
today but I will take a look at it tonight and see if what your saying
applies.
My Dataset and DataViewManager are global objects in this application and I
did notice that if I close and then re-open the form that the
DataViewManager.RowFilter setting is applied.
> Hi Jay,
> You don't seem to be getting any replies so I thought I would be it another
[quoted text clipped - 32 lines]
> >
> > Thanks