How can I convert the following strings to a System.DateTime object?
Wednesday 13th January 2010 Thursday 21st January 2010 Wednesday 3rd February 2010
Another approach.
string sDate = "Wednesday 13th January 2010"; string[] sFields = sDate.Split (' '); string day = sFields[1].Substring (0, (sFields[1].Length - 2)); DateTime date = new DateTime (sFields[3], sFields[2], day);