我想移除字符,单独提取"200803302320350"怎么做才可以?
string w_z ="http://www.ccnf.com/ccnf_assist/200803/termainal_200803302320350_0.shtml".ToString();
Response.Write(w_z.Trim('_'));
string w_z ="http://www.ccnf.com/ccnf_assist/200803/termainal_200803302320350_0.shtml".ToString();
Response.Write(w_z.Trim('_'));
Match M= Regex.Match(w_z, "(\\d){15}");
Response.Write(M.Groups[0].Value);
别忘了加using System.Text.RegularExpressions;记得给我撤分
Match M= Regex.Match(w_z, "_(\\d+)_");
Response.Write(M.Groups[1].Value);这样也可以,总之正则很强大,兄弟努力!