DateTime dateTime = (DateTime)SqlDateTime.Null;I was trying to show that a variable of type SqlDateTime could hold a value of null, while a variable of type DateTime could not. When I did the explicit conversion from SqlDateTime to DateTime, the DateTime variable had no way to represent null, so it was converted to '1/1/1900 00:00:00'. But you're saying that the SqlDateTime variable isn't actually null, or if I try to send it back to the database, it will be '1/1/1900 00:00:00'? Hmmm... interesting. And scary :-).
>DateTime dateTime = (DateTime)SqlDateTime.Null; >>Anyway, I see that you said that you didn't need to send anything back to the database, but if you did and if you set the DateTime column in your DataTable to SqlDateTime.Null and sent it back to SQL server, then you wouldn't see NULL in SQL Server anymore it would now be '1/1/1900 00:00:00'.