How to remove “ ” from java string

后端 未结 9 1546
遥遥无期
遥遥无期 2020-12-17 07:31

I have a java string with \" \" from a text file the program accesses with a Buffered Reader object. I have tried string.replaceAll(\" 

9条回答
  •  無奈伤痛
    2020-12-17 08:13

    I encountered the same problem: The inner HTML of the element I needed had " " and my assertion failed. Since the question has not accepted any answer,yet I would suggest the following, which worked for me

    String string = stringwithNbsp.replaceAll("\n", "");
    

    P.S : Happy testing :)

提交回复
热议问题