-
January 2nd, 2013, 08:26 AM
#1
Convert csv to xls
I need a program to convert csv to java under linux.(I dont like Perl, cause I dont underestand anything from it)
everyday some csv files are generated which I need them to be automatically converted to xls.
I need to modify csv thats why I need xls.
I dont know if any other informaion is needed.
I havent written anything because I am unable to write such a hard (for me) program.
Thanks alot in advance.
-
January 2nd, 2013, 10:51 AM
#2
Re: Convert csv to xls
We don't write code to order but we will guide you if you want to do it yourself and it's not that hard a task.
EDIT: Ignore the paragraph below - I mis-read your post and thought you wanted to convert CSV to XML. phillip.vu has posted a good solution.
To start with you need description of the data fields in the csv file and of the structure you want for the xml file.
If the csv file is small you may decide to read in, parse it, build the xml DOM and then write it, alternatively if the csv is likely to be large it may be better to read the file one line at a time, parse it and write that chunk of data to the xml file.
Last edited by keang; January 3rd, 2013 at 05:35 AM.
Reason: Mis-read OP's question
-
January 2nd, 2013, 09:03 PM
#3
Re: Convert csv to xls
Trying Apache POI.
The Apache POI Project's mission is to create and maintain Java APIs for manipulating various file formats based upon the Office Open XML standards (OOXML) and Microsoft's OLE 2 Compound Document format (OLE2). In short, you can read and write MS Excel files using Java. In addition, you can read and write MS Word and MS PowerPoint files using Java. Apache POI is your Java Excel solution (for Excel 97-2008). We have a complete API for porting other OOXML and OLE2 formats and welcome others to participate.
-
July 4th, 2013, 04:41 AM
#4
Re: Convert csv to xls
Use Aspose.Cells for Java, it can easily convert csv file to xls or xlsx in java and you don't need to go through all the coding to convert your file
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|