in my datagrid I insert a TextBlock and ComboBox for edit cell.
When I click in the cell for edit and I select an item of combox:
1) the item selected is not shown in cell of DataGrid.
2) my Convert is called two times.
Why?
XAML
My Converter:
public class DayNumName : IMultiValueConverter
{
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
{
if (values == null || values.Length < 4)
return null;
AnalysisPlanItemExt analisysPlanItem = (AnalysisPlanItemExt)values[0];
List
List
if (analisysPlanItem.Type != null)
{
//Day of Weeks
if (analisysPlanItem.Type.Value.Equals(Definition.SchedTypeEnum.DayOfWeek))
return listDayOfWeek;
if (analisysPlanItem.Type.Value.Equals(Definition.SchedTypeEnum.DayOfMonth))
return listDayNumOfMonth;
}
return null;
}
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
{
throw new System.NotImplementedException();
}
}
Thanks!

Roberto SalemiPosted Feb 26, 2015, 11:31 AM