Top "Replaceall" questions

The replaceAll() method in java (and similarly named methods in other languages) is used to replace all instances of a character in a string with another character.

String.replaceAll single backslashes with double backslashes

I'm trying to convert the String \something\ into the String \\something\\ using replaceAll, but I keep getting all kinds of …

java escaping backslash replaceall
replace \n and \r\n with <br /> in java

This has been asked several times for several languages but I can't get it to work. I have a string …

java regex replaceall
Java: Replace all ' in a string with \'

I need to escape all quotes (') in a string, so it becomes \' I've tried using replaceAll, but it …

java regex string replaceall
String replace a Backslash

How can I do a string replace of a back slash. Input Source String: sSource = "http://www.example.com\/value"; …

java string replace replaceall
How to change spaces to underscore and make string case insensitive?

I have following question. In my app there is a listview. I get itemname from listview and transfer it to …

java android string case-insensitive replaceall
groovy: how to replaceAll ')' with ' '

I tried this: def str1="good stuff 1)" def str2 = str1.replaceAll('\)',' ') but i got the following …

groovy replaceall
Regex using Java String.replaceAll

I am looking to replace a java string value as follows. below code is not working. cleanInst.replaceAll("[<i&…

java regex string replaceall
String replaceAll() vs. Matcher replaceAll() (Performance differences)

Pretty simple question, but this is coming from a C/C++ person getting into the intricacies of Java. I understand …

java regex string replaceall
Leave a cell blank if condition is false

Other questions have touched on this and offered solutions that are not viable for a very large data set. I …

excel if-statement find replaceall
How to replaceAll special characters in a string?

So to remove all the spaces in my string. I did a method that is consists of message = message.replaceAll("\\…

java string replaceall