You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
1.0 KiB
41 lines
1.0 KiB
|
2 years ago
|
using System;
|
||
|
|
using System.Collections.Generic;
|
||
|
|
using System.Linq;
|
||
|
|
using System.Text;
|
||
|
|
using System.Threading.Tasks;
|
||
|
|
using System.Windows;
|
||
|
|
using System.Windows.Data;
|
||
|
|
using System.Windows.Input;
|
||
|
|
using System.Windows.Controls;
|
||
|
|
|
||
|
|
namespace Audit.ConvertMoels
|
||
|
|
{
|
||
|
|
internal class StatenERRConvert : IValueConverter
|
||
|
|
{
|
||
|
|
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||
|
|
{
|
||
|
|
if (value == null)
|
||
|
|
{
|
||
|
|
return null;
|
||
|
|
}
|
||
|
|
else
|
||
|
|
{
|
||
|
|
if (value.ToString() == "309")
|
||
|
|
{
|
||
|
|
return "red";//零返回红色
|
||
|
|
}
|
||
|
|
else
|
||
|
|
{
|
||
|
|
return "black";//非零返回黑色
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||
|
|
{
|
||
|
|
throw new NotImplementedException();
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|