title: How to restrict special symbols like % in textbox in wpf?
body: <p>I would like to develop a textbox which restricts special symbols like %. I used textbox's keydown event to restrict '%' . I already used the code as</p>
  
  <pre><code>if(Keyboard.Modifiers == ModifierKeys.Shift &amp;&amp; e.key == key.D5)    
  {    
      e.handle=true;    
      return;    
  }
  </code></pre>
  
  <p>when i implement this in mvvm architecture, I got problem with the dependency property that recognizes only shift as one key and D5 as another when I converted systemkey into string format.</p>
  
  <p>How can I recognize % symbol?</p>