Greetings Kevin,
Should there be a check to see if DE.Value is null in the for each loop and set to System.DBNull.Value if it is?
Regards,
E.R.
>Kevin,
>
>In the BindBack method code (starting with line 217) in mmGridView the value in DE.Value is null. This is where the ArgumentException is occurring. The timestamp on the mmGridView.cs is 8-17-2007 and the MM.Net Web Forms dll is 8-24-2007.
>
>
>
>OrderedDictionary ODictionary = new OrderedDictionary();
>TemplateField TField = column as TemplateField;
>if (TField != null)
>{
> TField.ExtractValuesFromCell(ODictionary, (DataControlFieldCell)cell, DataControlRowState.Edit, false);
> foreach (DictionaryEntry DE in ODictionary)
> {
> ds.Tables[tableName].Rows[this.EditIndex][DE.Key.ToString()] = DE.Value;
> }
>}
>
>
>>E.R.,
>>
>>>The table this is saving to has a date field that accepts nulls. I'm editing the row that had a null date to begin with. After editing a field (not the date field in question) I get the ArgumentException while trying to update. I tried checking the date field before saving and setting it to System.DBNull.Value, but that doesn't work.
>>
>>I recommend setting a breakpoint in mmGridView.BindBack() to see exactly what's going on.
>>
>>Best Regards,
Regards,
E.R. Gilmore