日期:2014-05-19  浏览次数:20803 次

取字符串问题,在线等
一个字符串,比如
string   s   =   "123xxx456xxx789xxx ";

我要分别取123,456,789出来,应该怎么做?



------解决方案--------------------
string[] ns=s.Replace( "xxx ", "x ").Split( 'x ');
------解决方案--------------------
string[] ns=s.Replace(new char[ 'xxx ']);