Search code examples
asp.net-mvcdatetimedeploymentglobalization

Regional settings on deployment machine for datetime not performing


I deployed the application on normal windows 7 machine as it is central machine for official use. this is internal use application. bu the datetime manipulation on the deployed machine not working properly. since everything if working properly on development machine. I thought it might be the Regional settings issue but as i settled up same settings on deployment machine same like development machine, still issue is same. issue is deployment machine unable to understand the which is MM and dd. suppose i am sending date like "11-jul-2013" then somehow it converting it to "11-07-2013" this is ok. but date 13 will not work for this case.

Edited: I added

   globalization:
   fileEncoding="utf-8"
   requestEncoding="utf-8"
   responseEncoding="utf-8"
   culture="en-US"
   uiCulture="en-US"

in the web.config. but still problem is same. what should be the issue? really I am stuck.


Solution

  • Sounds like it could be an issue with your culture settings. Try debugging by checking what culture is currently set (CultureInfo.CurrentCulture) right before you are using the date.