I like to know how to replace a regex-match of unknown amount of equal-signs, thats not less than 2... to the same amount of underscores
So far I got this:
You can use Regex.Replace(String, MatchEvaluator) instead and analyze math:
string result = new Regex("(={2,})") .Replace(text, match => new string('_', match.ToString().Length));