locked
Date formats and cultures RRS feed

  • Question

  • User-140674451 posted

    I have come across an issue with date formats under a different culture.

    I can give you a sample scenario.

     Convert.ToDateTime(Eval("RunDate")).ToString("ddMMMyyyy").ToUpper()

    the above approach will give "20JUL2005" for en-CA and 

    "20JUIL.2005" for fr-CA.

    French users see the french version to be wrong.

    So who is right here? Microsoft or the French users?

    Is there a way I can get the french version to be "20JUI2005" without resorting to hard coded mappings.

    Please give some insights.

    Thanks

    Friday, January 31, 2014 11:40 AM

All replies

  • User753101303 posted

    It looks quite good even according to wikipedia now I'm not sure you really have anything official regarding month abbreviation...

    What do they want instead ? Never tried but I noticed once that you can customize a culture as needed (including replacing an existing culture). Try http://msdn.microsoft.com/en-us/library/ms172469(v=vs.90).aspx

    With this you should be able to handle this without any code change (or at least located at a single place in your once for all customization) and easily revert back etc... if you want...

    Friday, January 31, 2014 12:46 PM
  • User-140674451 posted

    What they dislike the most is the dot after the month part.

    Friday, January 31, 2014 1:57 PM