I have a series of pages that are using an inventory that is an ObservableCollection<myType>()
but there are multiple instances with different myTypes
. I want to make a converter that is going to display or hide a page element based on whether or not this list is populated.
Basically the functional code of the converter would look like
return (((ObservableCollection)value).Count) < 1);
But I have to type the ObservableCollection
to be able to get to the count
.
Is there a way to cast this so I can just see how many elements exist in the collection?