Noone ever told you how to put a speechmark " into a string in VB? 
Code:
Public Function CleanInput(strIn As String) As String
' Replace invalid characters with empty strings.
Return Regex.Replace(strIn, "[^A-Z0-9,+""]", "")
End Function Note the double speechmark "" which does not 'break the string' because VB understands to escape this to a single speechmark
The following code MAY match outside Chr 33 to Chr 125 and replace it with nothing:
Code:
Public Function CleanInput(strIn As String) As String
' Replace invalid characters with empty strings.
Return Regex.Replace(strIn, "[^\u0021-\u007D]", "")
End Function I say may because I've never really used the unicode specifiers; try it
Bookmarks