I\'m trying to do an \"empty list to visibility converter\" for WPF. This is an IValueConverter that takes an object ( that should be a list ) and if the list is empty (or i
My guess is that it's because of the fact that you're using IList
in the converter but your actual collection is an IList
. See, IList is not covariant so you can't just convert any IList
to an IList
. My suggestion will be to try and use IEnumerable
in the converter instead and use the Count() extension method to determine the number of items in the collection.