Hello,
We have a web application that produces reports. Data are taken from a database.
When we ran the web application on a localized system, it blows up. We traced the problem on a DateTime.Parse(dateString); call.
The dates stored in the database is somewhat dependent on the locale of the machine.
On an English system, the date is stored as MM/DD/YYYY (06/25/2009) which is perfectly normal.
On a Russian system, the date is stored as MM.DD.YYYY (06.25.2009). This is weird because the default setting (I checked) for Short Date format in Russian Systems is dd.MM.yyyyy... So it should be 25.06.2009. I don't it get why it accepted the default separator (.) but not the default date format.
So anyway, how can I parse the date string on a localized system? If I use the Russian cultureinfo, it would still throw an error since it is expecting dd.MM.yyyyy.
Thanks!