-1

hi , can anyone tell me how to read contents of a CSV file into my java string. and how to convert a CSV file to a Excel file in java .

3
Contributors
3
Replies
5
Views
10 Years
Discussion Span
Last Post by iamthwee
0

hi , can anyone tell me how to read contents of a CSV file into my java string. and how to convert a CSV file to a Excel file in java .

To read in a csv file, would be just the same as reading in a normal text file.

You would just use the split() method to separate your lines by the commas.

Converting a CSV to excel would be more difficult. However, there should be some third party programs you can use to do that bundled up as a jar file. In fact I've used one successfully before.

0

or you can write your own, outputting SLK for example.
The format is well described and though messy offers flexibility.

Technically of course you wouldn't have to do anything as Excel can read and interpret CSV files directly ;)

0

Technically of course you wouldn't have to do anything as Excel can read and interpret CSV files directly

Oopsie. I didn't even think of that.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.