摘要: 方法一:Convert.ToDateTime(string)string格式有要求,必须是yyyy-MM-dd hh:mm:ss================================================方法二:Convert.ToDateTime(string, IFormatProvider)DateTime dt;DateTimeFormatInfo dtFormat = new System.GlobalizationDateTimeFormatInfo();dtFormat.ShortDatePattern = "yyyy/MM/dd";dt 阅读全文
posted @ 2013-05-07 15:23 蓝晓 阅读(187) 评论(0) 推荐(0) 编辑
摘要: http://www.cnblogs.com/jerryhu/archive/2009/11/10/1599963.htmlhttp://dotnetperls.com/datetime-formatProblem. You need help with DateTime formatting strings in C# or .NET languages. The framework provides powerful formatting capabilities, but the syntax is confusing and there are some tricks. Solutio 阅读全文
posted @ 2013-05-07 14:48 蓝晓 阅读(491) 评论(0) 推荐(0) 编辑