title: Check string for invalid characters? Smartest way?
body: <p>I would like to check some string for invalid characters. With invalid characters I mean characters that should not be there. What characters are these? This is different, but I think thats not that importan, important is how should I do that and what is the easiest and best way (performance) to do that?</p>
  
  <p>Let say I just want strings that contains <strong>'A-Z', 'empty', '.', '$', '0-9'</strong></p>
  
  <p>So if i have a string like "<strong><em>HELLO STaCKOVERFLOW</em></strong>" => invalid, because of the 'a'.
  Ok now how to do that? I could make a <code>List&lt;char&gt;</code> and put every char in it that is not allowed and check the string with this list. Maybe not a good idea, because there a lot of chars then. But I could make a list that contains all of the allowed chars right? And then? For every char in the string I have to compare the <code>List&lt;char&gt;</code>? Any smart code for this? And another question: if I would add A-Z to the <code>List&lt;char&gt;</code> I have to add 25 chars manually, but these chars are as I know 65-90 in the ASCII Table, can I add them easier? Any suggestions? Thank you</p>