Escape C# Strings

If you have a string that you'd like to put in your C# code files, but it needs a lot of characters escaped, this form will regenerate it for you as a codedom formatted string.

XML or JSON, any old thing in here will be converted to a nice source string down there.

This should be ready to paste straight into your .cs file.

From a StackOverflow Answer. Assembled by Josh Rivers of Recursive Erudition. Source Code on BitBucket.