public DateTime ConvToDate(string dateString) { DateTime result; string[] a = new string[] { "dd/MM/yyyy", "MM/dd/yyyy", "MM/dd/yy", "ddMMMyyyy", "dMMMyyyy","dd-MM-yyyy","MM-dd-yy","MMM dd" }; result = DateTime.ParseExact(dateString, a, System.Globalization.CultureInfo.CurrentCulture, System.Globalization.DateTimeStyles.None); return result; }
dateString
a
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)