现有字符串 
string str="2012-07-05\x2021\x3A52\x3A44";
转换成  DateTime
求高手给出代码  谢谢

解决方案 »

  1.   

    \x2021\x3A52\x3A44这个是什么意思?
    如果只是转换"2012-07-05",那么先截取出来,在用Convert.ToDateTime()进行转换
      

  2.   

    http://msdn.microsoft.com/zh-cn/library/9xk1h71t
    Convert.ToDateTime需要的datetime字符串格式
      

  3.   

    记得还有一个包括时区转换的,楼主自己在msdn看看
      

  4.   

    \xabcd, \x 后面跟的是0xffff字符代码!
      

  5.   

    http://www.cnblogs.com/huanglong/archive/2012/03/26/2417487.html
    看看或许对你有帮助!!