using System; using System.Collections.Generic; using System.Globalization; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; using System.Windows.Data; namespace PDF_Office.DataConvert { public class SignatureButtonConvert : IMultiValueConverter { public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture) { if (values[0] == null || values[1] == null || values[2] == null) { return false; } else { if ((int)values[0] == 0 && !string.IsNullOrEmpty((string)values[1])) { return true; } if ((int)values[0] == 1 && (int)values[2]>0) { return true; } if ((int)values[0] == 2 && values[3]!=null) { return true; } } return false; } public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture) { throw new NotImplementedException(); } } }