VB.NET - Conversion from string "11/07/2010 13:00:00" to type 'Date' is not valid
I am getting the error: Conversion from string "11/07/2010 13:00:00" to type 'Date' is not valid. In my ASP.NET code when run on the web server. The date is valid and it can't be a US format issue because either way it would be valid. I have tested it and it seems to error when the time is > 12:00 (ie. a 24h开发者_如何转开发our like 13:00 or 21:00).
I've googled and only found a sugeestion to bounce IIS on the server.
Any ideas why ???
thanks Dave
Use the DateTime.TryParseExact()
method.
精彩评论