ASP.Net MVC model binding - how to change date format?
I have this application, and the default date format must be dd/MM/yyyy (the language is Brazilian Portuguese). I already had set culture and UI culture to pt-BR and now myDate.ToShortDateString() returns the dates as I want. I have no trouble displaying them. The problem is, when the user fills an input field with a date such as 17/08/2011 and submits the form the DateTime parameter to my action becomes null. If I supply a date in the format 08/17/2011 , it works fine. How can I make the ASP.Net MVC model binding to parse my dates correctly? I found what happended. My form was posting via GET