title: Regex not working as should in .Net
body: <p>I trying to replace some line breaks from a file in C#, given a specific pattern:</p>
  
  <p><code>(?m)(^\t[0-9A-Z#].+$)\r?\n</code></p>
  
  <p>File example structure</p>
  
  <pre><code>    1   1   1   1
  ab  as  as  
      123 1   2
          13
      32  3   12  2
  ds  ds  12
  </code></pre>
  
  <p>Applying <code>$1\t</code> as replace, I expect to get the following result:</p>
  
  <pre><code>    1   1   1   1   ab  as  as  
      123 1   2           13
      32  3   12  2   ds  ds  12
  </code></pre>
  
  <p>In fact, this replace is working properly at <a href="http://regexr.com/396mp" rel="nofollow">regexr</a>.</p>
  
  <p>But in C# the file simply return no matches. Is any particularity in this regex that .net matches differentially? </p>
  
  <pre><code>public void masterDataEleb()
  {
      // Tried both with (?m) and RegexOptions.Multiline, not working
      Regex masterDataRegex = new Regex(@"(^\t[0-9A-Z#].+$)\r?\n", RegexOptions.Multiline);
      string replaceTo = "$1\t";
  
      string textFile = File.ReadAllText(filePath, Encoding.Default);
      textFile = masterDataRegex.Replace(textFile, replaceTo);
  
      File.WriteAllText(filePath, textFile, Encoding.Default);
  }
  </code></pre>