This project is read-only.
1
Vote

String Replace doesnt work with blanks

description

Hey,

i was using the String Replace function, which works fine but for one thing: I want to remove blanks (" ") from a String.
So my Field 2 is " " (without the apostrophes), and my field 3 is just empty.
But when I save the workflow and reopen it, the blank is not there anymore (cause CRM naturally deletes blank fields), it is an empty field, and the result comes out untouched.

How can i correctly delete a blank from my String?

(Also the Trim function wont solve the problem, I guess it only trims the start and end of the string)

Thanks in advance!

Georg

comments

ghass wrote Oct 23, 2014 at 9:24 AM

Issue solved -
I couldnt do it with the string-replace function, but with the RegEx-Replace.

But i hat to do it in two steps:

first get the blank and replace it:
replace \s+
with something else - import is, you cant use a empty field here, then it just doesn't work.

so i used regex to substitute blanks with a comma,
and another string replace to substitute commas with empty fields - that workaround worked.

AndreasNilsen wrote Feb 3, 2015 at 11:41 AM

Thanks this worked fine for me!