Nick Burch <nick.burch <at> alfresco.com> writes: > > On Wed, 23 Feb 2011, Donato wrote: > > I'll open the bug. Could you provide some complete examples in order to > > use the XSSFTable object? (I had a look both at the javadoc and at the > > source files, but it seems a bit tricky.., it is not clear to me how to > > move from the workbook object already created to the document parts). > > I've personally no idea what an xssf table is, or why you'd want one... So > I've no specific code to hand! > > You'll want to get the document part of the workbook. Then, ask the > openxml4j package code to give you the part for your table. > (XSSFRelation.TABLE has most of the things you need to do it, and look in > POIXMLDocument for the code to do it). When you have the table package > part, create a xssf.model.Table object with it, and you're away > > Nick >
Ok, I'll try to use the POIXMLDocument class (which is the superclass of a XSSFWorkbook, if I'm right). A question: I'm creating workbook objects as Workbook wb = new HSSFWorkbook(myfile.xls) or Workbook wb = new XSSFWorkbook(myfile.xlsx) Are there any difference, especially for the XSSFTable I'm interested in, between these declarations and HSSFWorkbook wb = ... or XSSFWorkbook wb = ... ? (Anyway, I also tried both, and it always seems that I cannot get the map info neither from the xml nor the binary format). I think that your solution (using the POIXMLDocument) will work only for xlsx files, won't it? Thanks, Donato --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
