The files used in this walkthrough can be downloaded here: DiscardChar.doc and DiscardChar.pdf.
var v = event.change.replace(/[#@+!\\\[\]]/, "");
if(v == event.change)
event.change = v;
Note: the first parameter in the above replace() function is a regular expression enclosed by two slashes. The script will replace the text that matches the regular expression in a keystroke input (this may include copy and paste action) with an empty string, and keep looping until nothing is replaced.