Пример #1
0
        public object Convert(object value, System.Type targetType, object parameter, CultureInfo culture)
        {
            int sizeINT = (int)value;

            BUS.BUS_Size busSize = new BUS.BUS_Size();

            for (int i = 0; i < busSize.GetAllSizes().Count; i++)
            {
                if (sizeINT == busSize.GetAllSizes()[i].ID)
                {
                    return(busSize.GetAllSizes()[i].SizeName + $" ({sizeINT})");
                }
            }

            return("");
        }