42 lines
1.0 KiB
C#
42 lines
1.0 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Globalization;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Windows.Data;
|
|
|
|
namespace DeerProject.Common
|
|
{
|
|
public class BtnConvert : IMultiValueConverter
|
|
{
|
|
|
|
public static object ConvertObject;
|
|
|
|
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
|
|
{
|
|
string result = "";
|
|
for (int i = 0; i < values.Length; i++)
|
|
{
|
|
if (values[i] == null)
|
|
break;
|
|
|
|
if (i != values.Length - 1)
|
|
{
|
|
result += values[i].ToString() + ",";
|
|
}
|
|
else
|
|
{
|
|
result += values[i].ToString();
|
|
}
|
|
}
|
|
return result;
|
|
}
|
|
|
|
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
|
|
{
|
|
throw new NotImplementedException();
|
|
}
|
|
}
|
|
}
|