ISO 8601 into a datetime object using C#
Possible Duplicate:
How to create a .NET DateTime from ISO 8601 format
How can I parse a date string in ISO 8601 format into a datetime object using C#?
Use one of the ISO 8601 standard date and time format strings - "O", "o" , "S" and "s" when parsing the string (aka the Roundtrip format specifier) .
The pattern for this specifier reflects a defined standard (ISO 8601). Therefore, it is always the same regardless of the culture used or the format provider supplied.
DateTime dt = DateTime.ParseExact(iso8601String, "s", CultureInfo.InvariantCulture);
链接地址: http://www.djcxy.com/p/46544.html