title: Html encoding in .NET class library
body: <p>I have a utility class for sending emails. The emails are generated as html.</p>
  
  <p>I'm having problems with encoding special characters which aren't getting displayed correctly.</p>
  
  <p>However, I can't work out how to use <code>HtmlEncode</code> as I don't have a current <code>HttpContext</code>. Is there a <code>.Net</code> class which will translate special characters to html codes without running under <code>Asp.Net</code>?</p>
  
  <p>I hope that makes sense, I'm a bit flaky about how all this stuff works. Thanks!</p>