You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
876 B
C#

using System;
1 year ago
using System.Globalization;
using System.Windows.Data;
namespace Aucma.Scada.UI.ConvertToObj.LinerInventory
1 year ago
{
1 year ago
public class StatusLabelConverter : IMultiValueConverter
1 year ago
{
1 year ago
public object Convert(object[] value, Type targetType, object parameter, CultureInfo culture)
1 year ago
{
if (value == null)
{
return false;
}
else
{
1 year ago
int info = (int)value[0];
1 year ago
if (info == 1)
{
return "green";
}
else
{
return "red";
}
}
}
1 year ago
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
1 year ago
{
throw new NotImplementedException();
}
}
}