I'm using the datagrid 4.0 WPF
for some time now - and it's great :-)
One problem I have is that the
auto filter (excel like) does not work correctly when the field in the datagrid
has a currency data template applied.
When I click the auto filter
instead of seeing a list of values - I see the name of the field again and
again...
The data template is here:
<DataTemplate
x:Key="currency_celltemplate">
<TextBlock Text="{xcdg:CellEditorBinding Converter={x:Static
local:CustomCurrencyConverter.Instance}}"/>
</DataTemplate>
The Converter is simple:
public object Convert(object
value, Type targetType, object parameter, CultureInfo culture)
{
try
{
string cur=string.Format("{0:c}", value);
return cur;
}
catch (Exception ex)
{
Message.ShowInfo(ex.Message,
"Error applying currency format");
return value.ToString();
}
}
Any ideas?