C# 正则表达式

1、工具

http://download.csdn.net/download/yuki16480/1543171

http://deerchao.net/tools/regester/index.htm

 

2、基本语法

            // 获取addressid
            Regex reg = new Regex(@"updateAddress\((.+?)\)");
            MatchCollection match = reg.Matches(html);
            if (match.Count > 0) {
                string v = match[0].Groups[1].Value.ToString();
            }
            else {

            }

 

posted @ 2017-11-24 21:28  贝尔塔猫  阅读(171)  评论(0编辑  收藏  举报