I just found that my SqlDateTime.MinValue is different on different machines.
Sometimes it is = DateTime(1953, 1, 1, 0, 0, 0);
but on other machines it is = DateTime(1753, 1, 1, 0, 0, 0);
How can that be? OS on both machines is WinXP SP2.
Edit:
My code was like this:
DateTime date;
...
if (date == SqlDateTime.MinValue)
{
return "(any)";
}
else
{
return date.ToString();
}
This code should never return January 1, 1753 but it did (on some machines). The minutes and seconds of date are not used by my code and should always remain default values.