0

Hi
I consider myself fairly new to VB.NET, so maybe you could help me here.
I have a bindingSource which is bound to a dataset. I have a filter on the bindingsource. My problem is that when I add a new row, with BindingSource.AddNew, even if it does not match the filter criteria, it still isn't filtered out.
Could it be that the bindingsource filter never filters out detached rows? If so, what can I do in this situation?

Example

Me.TblStempelkarteBindingSource.Filter = "Month = " & getCurrentDate.Month & _
                                                " AND  Day = " & getCurrentDate.Day & _
                                                " AND  Year = " & getCurrentDate.Year

I add a new row to the BindingSource and then do BindingSource.Count. The count always includes the added row, even if the fields do not match Month/Day/Year of my filter.
Thank You!

2
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by winkler
0

I removed the filter and then applied it again. Doesn't seem to work. Any other suggestions?

0

I didn't find a solution to this problem, but I was able to work around it.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.