0

I'm reading some integer values from a webpage using Java through Jsoup library. In the website integer represented as xxx,xxx. I need this set of data to be written in a .csv file so later it can be accessed through Excel for further work.

How to remove this comma in the middle so it doesn't affect the .csv file?

Pshemo
  • 122,468
  • 25
  • 185
  • 269
Zeemaan
  • 333
  • 3
  • 7
  • 17

4 Answers4

1

string.replace(",", " "); should do it

j.con
  • 879
  • 7
  • 19
1
   if you want to remove any charactor from a string you can use it.

   String name="sri,sha,ila,m";

   name = name.replace(",","");

   Output : srishailam 
0

It must be a string when you get it so could use firstInstanceOf to find and then remove it

onesixtyfourth
  • 744
  • 9
  • 30
0

I believe that string.replace(",", "") will solve your problem. This question will help String not replacing characters.

Community
  • 1
  • 1