How do I parse and convert a DateTime to the RFC 3339 date-time format?
How do I convert a DateTime structure to its equivalent RFC 3339 formatted string representation and/or parse this string representation back to a DateTime structure? The RFC-3339 date-time format is used in a number of specifications such as the Atom Syndication Format . Matt Howells You don't need to write your own conversion code. Just use XmlConvert.ToDateTime(string s, XmlDateTimeSerializationMode dateTimeOption) to parse a RFC-3339 string, and XmlConvert.ToString(DateTime value, XmlDateTimeSerializationMode dateTimeOption) to convert a (UTC) datetime to a string. Ref. http://msdn