Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Remove Special Characters and White Spaces in a string
#1
I have a string say !@#$%%^&ME and Bobby ! MckGee#@$%^. I want to strip all of the special characters and white spaces out. In python this line of code would do it re.sub(r'((?![a-zA-Z0-9]).)+', '', line) which uses regular expressions. I cannot seem to get this to work in QM with findrx or replacerx. I know I am doing something wrong, This is the Regex that is key ((?![a-zA-Z0-9]).)+'

Anybody know how to do this?


edit

this is what I would expect back
MEandBobbyMckGee


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)