Hey Peter, Did the same and I think I understand the issue. The package line at the start of the java files are needed unless you make further code changes. To fix the issue, unzip the file you downloaded from http://chris-lott.org/software/, and create the directory tree org\chris_lott\xlsx2csv (on Windows) or org/chris_lott/xlsx2csv (on *nix). Move the unzipped java files into the xlsx2csv directory but do not change to this directory. From the parent directory of org type:
javac org/chris_lott/xlsx2csv/XLSX2CSV.java (works on Windows and *nix) then java org.chris_lott.xlsx2csv.XLSX2CSV workbook.xlsx changing workbook.xlsx to the path and name for the workbook you wish to convert to csv. HTH, Bobby -----Original Message----- From: peterconn [mailto:[email protected]] Sent: Friday, October 09, 2009 19:01 To: [email protected] Subject: Compiling XLSX2CSV example using XSSF Hi, I copied the XLSX2CSV example using XSSF from this forum but have trouble getting a clean compile. My java skills are limited so I simply compile from the command line using javac. I have downloaded the latest POI release from Apache as poi-bin-3.5-FINAL-20090928.zip and unzipped all the jar files and added these to my classpath. poi-ooxml-3.5-FINAL-20090928.jar poi-scratchpad-3.5-FINAL-20090928.jar poi-contrib-3.5-FINAL-20090928.jar poi-3.5-FINAL-20090928.jar commons-logging-1.1.jar geronimo-stax-api_1.0_spec-1.0.jar xmlbeans-2.3.0.jar dom4j-1.6.1.jar junit-3.8.1.jar log4j-1.2.13.jar ooxml-schemas-1.0.jar The compile initially failed to find the ReadonlySharedStringsTable class so I downloaded that code from this forum and complied class ReadonlySharedStringsTable on the first attempt. Please note that the only change I made was to remove the package statement. I simply compiled ReadonlySharedStringsTable into my local directory as I normally do with other classes. Before compiling XLSX2CSV I also remove the package statement inserted by Chris Lott. But this compile fails with the error - XLSX2CSV.java:376: cannot find symbol symbol : constructor ReadonlySharedStringsTable(org.apache.poi.openxml4j.opc.OPCPackage) location: class ReadonlySharedStringsTable ReadonlySharedStringsTable strings = new ReadonlySharedStringsTable(this.xlsxPackage); This package thing has me confused. Can anybody help? Cheers, Peter -- View this message in context: http://www.nabble.com/Compiling-XLSX2CSV-example-using-XSSF-tp25829140p25829 140.html Sent from the POI - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
