For reasons beyond my control, I find myself using .net mobile 3.5. I need to be able to use the Rows.Find(Object) function on a DataTable where the Primary Key is a DateTime.
Ex: DataRow temp = exDataSet.exDataTable.Rows.Find(exDateTime);
I have not been able to make the C# DateTime value match that which is stored in the DataTable.
Based on guidance from these forums and from other resources I have tried changing the DataColumn's DateTimeMode
, I have tried converting the DateTime to SqlDateTime, and I have tried the (much less desired) .ToString("yyyy-MM-dd HH:mm:ss")
function, all to no avail. Also, I am unable to use DateTime2 as far as I am aware.
Any recommendations?