I'm building a token that could have double spaces. How can I use Regular Expressions to find and replace the double space or another way doing this in workflow.
Thank you!
I'm building a token that could have double spaces. How can I use Regular Expressions to find and replace the double space or another way doing this in workflow.
Thank you!
This assumes your source token is two words separated by one or more spaces. Create two more tokens called beginning and end. Set their values from the source token using the regular expressions below.
Beginning has the regular expression: ^(\w+)\s+ This captures word characters from the start of the source token, but only when followed by one or more spaces.
End has the regular expression: \s+(\w+)$ This captures word characters from the end of the source token, but only when preceded by one or more spaces.
Use those two tokens to rebuild your original token, adding only a single space between them.