Odd behaviour replacing "\"
<p>I have this issue in which I have a strnig with among other things the literal expression <code>"\\"</code> on several occasions and I want to replace it with <code>"\"</code>, when I try to replace it with string.replace, only replcaes the first occurrence, and if I do it with regular expression it doesn't replace it at all</p>

<p>I checked with some RegEx Testers online and supposedly my code is ok, returns what I meant to, but my code doesn't work at all</p>

<p>With <code>string.replace</code></p>

<pre><code>example = "\\\\url.com\\place\\anotherplace\\extraplace\\";

example = example.replace("\\\\","\\");

returns example == "\\url.com\\place\\anotherplace\\extraplace\\";
</code></pre>

<p>With RegEx</p>

<pre><code>example = Regex.Replace(example,"\\\\","\\");

returns example = "\\\\url.com\\place\\anotherplace\\extraplace\\";
</code></pre>

<p>It is the same case if I use literals (On the Replace function parameters use <code>(@"\\", @"\")</code> gives the same result as above).</p>

<p>Thanks!</p>

<p><strong>EDIT:</strong></p>

<p>I think my ultimate goal was confusing so I'll update it here, what I want to do is:</p>

<p><em>Input:</em>
variable that holds the string: <code>"\\\\url.com\\place\\anotherplace\\extraplace\\"</code></p>

<p><em>Process</em></p>

<p><em>Output</em>
variable that holds the string <code>"\\url.com\place\anotherplace\extraplace\"</code>
(so I can send it to ffmpeg and it recognizes it as a valid route)</p>
