DateTime.TryParseExact 万能时间格式转化 DateTime.TryParse
private DateTime convertDASTime(string s) { DateTime result; if (DateTime.TryParseExact(s, "yyyyMMddHHmmss", null, System.Globalization.DateTimeStyles.None, out result)) { return result; } return DateTime.ParseExact(s, "yyyyMMddHHmmssfff", System.Globalization.CultureInfo.CurrentCulture); }