楼主是想用正则表达式来替换吧。那应该是这样的用法:
wenben3.Text= System.Text.RegularExpressions.Regex.Replace(@"href=\"[^\"]*\"","href="+"convert.aspx?Url=");

解决方案 »

  1.   

    没看懂void DumpHrefs(String inputString) 
        {
            Regex r;
            Match m;        r = new Regex("href\\s*=\\s*(?:\"(?<1>[^\"]*)\"|(?<1>\\S+))",
                RegexOptions.IgnoreCase|RegexOptions.Compiled);
            for (m = r.Match(inputString); m.Success; m = m.NextMatch()) 
            {
                Console.WriteLine("Found href " + m.Groups[1] + " at " 
                    + m.Groups[1].Index);
            }
        }
      

  2.   

    呵呵,String.Replace方法是直接的替换,不支持正则表达式。若要使用正则表达式,则应该用
    System.Text.RegularExpressions.Regex类的Replace方法