Hi ALL,
I've got some date fields that will end up being null, but I can set it to
some other date. However, I tried setting the fields to "01/01/1900", and I
get the same error on that as well. Can someone tell me what I'm doing
wrong? I've tried a bunch of different combinations, but nothing I do seems
to make any difference. I even tried casting it to a DateTime, but got a
compile error (cannot convert type "string" to 'System.DateTime')..
TIA, Randy
if (js.StartDate != null)
{
cm.Parameters.AddWithValue("@startDate", js.StartDate);
}
else
{
cm.Parameters.AddWithValue("@startDate", "01/01/1900");
}