Regular Expression help

Regular Expression help

Hi, 

Can anyone please help me to write reg expression of below. 

I want to validate a string field so it will not allow user to enter any of the below special characters

Characters   :     ~  #   @  *  +  %  {  }  <>   []  | "   \   _



here is the example something I have been using for validating phone number  :

  1. phoneNoFormat = input.TFN_01.toString().replaceAll("^[0-9]{3}-[0-9]{3}-[0-9]{4}$","correct");
  2. if (phoneNoFormat  !=  "correct")
  3. {
  4.     alert("Phone Number should be in the format of " + "<b>" + "111-111-1111");
  5.     cancel submit;
  6. ?


Thanks

Arfater