I can answer at least part of your question. You should re-use style objects once they have been created. By this, I mean that if you have, for example, one hundred cells all of which share the same style, one style object should be created and applied to each in turn.
The reason that you cannot get a cell style obhect by name from the XSSFWorkbokk is, I am assuming, that no one has yet defined and created that method. The XSSF stream is not a fully mature api yet and work is still taking place on filling in the 'holes' so to speak. If yu ask on the list, I am certain that someone will quite happliiy offer to help you. This is also a guess but I think it should be possible to get the style by name from the OpenXML layer that underpins the XSSF stream. However, to do this would be to create the functionality necessary to add a getStyleByName() method into the XSSFWorkbook class so it would bve just as easy to workup a patch in my opinion. -- View this message in context: http://apache-poi.1045710.n5.nabble.com/Question-about-XSSFCellStyle-tp5719982p5719985.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]
