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
  • 118,400
  • 24
  • 176
  • 257
Zeemaan
  • 311
  • 2
  • 7
  • 15

4 Answers4

1

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

j.con
  • 872
  • 7
  • 18
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
  • 694
  • 8
  • 26
0

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

Community
  • 1
  • 1