using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Dynamic; using System.Globalization; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Data; namespace Metadata_Translator { public class CollectionEmptyTrueFalseConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { return (value is ObservableCollection collection) ? collection.Count > 0 : false; } public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { throw new NotImplementedException(); } } }