string fixed = Regex.Replace(input, Regex.Escape("?"), "");

Although a string Replace is just as good for this simple case. I know that
if you're doing lots of this sort of thing in a more general and more
complicated way then creating a new Regex instance just for the purpose is
more efficient as it internally *Emit*s optimised code for the expression.

Greg

Reply via email to