1
Answer

Linq Error

David Smith

David Smith

11y
1.7k
1
I get this error for the linq below.


Error:  at least one object must implement icomparable


var minDate1 = (from c in DataAccess.VolunteerHistoryDataSet.Tables[0].AsEnumerable()
                                where c["ServiceDateStart"] != DBNull.Value
                                orderby c["ServiceID"], c["ServiceDateStart"]
                                select new
                                {
                                    Date = Convert.ToDateTime(c["ServiceDateStart"])
                                }).ToList().Min();
Answers (1)