title: How to convert a character to key code?
body: <p>How can I convert backslash key ('\') to key code?</p>
  
  <p>On my keyboard backslash code is 220, but the method below </p>
  
  <pre><code>(int)'\\'
  </code></pre>
  
  <p>returns me 92.</p>
  
  <p>I need some generic conversion like </p>
  
  <pre><code> int ConvertCharToKeyValue(char c)
   {
       // some code here...
   }
  </code></pre>
  
  <p>Any ideas?</p>