views:

39

answers:

1

How do I explicityl call something like 'DoFilter' on System.Windows.Controls.ItemCollection?

I set up it's Filter property to a Predicate. I placed a breakpoint in the predicate, it reaches there only when the ItemsCollection is initialized, when I call m_ItemsCollection.Refresh() it's not.

+1  A: 

There are several situations where .Refresh() doesn't work but this does:

collection.Filter = collection.Filter;

I ran into this several months ago. Apparently there is a bug that keeps ItemsControl from reliably passing down the Refresh() call in certain situations. I have not investigated the details.

Ray Burns