Not able to replace double underscores

when i have single underscore ex: _ , the replace works but if a string has more than one underscores together, ex: __   or ___ then the replace function does not work. i get the same text back. any idea how to to get this to work.
1 answers

are you using the replaceAll function?


if so, take a look at the documentation of that function, this function is using a regex as a parameter : 

"The regular expression to match; if you want to search for a literal string, enclose it between \Q and \E (for example, \QPaul S. Mueller\E will search for the string Paul S. Mueller, without interpreting the dot as a wildcard)"