https://bz.apache.org/bugzilla/show_bug.cgi?id=60633
Bug ID: 60633
Summary: Apache POI 3.13 generated powerpoint file cannot be
opened
Product: POI
Version: unspecified
Hardware: Macintosh
OS: Mac OS X 10.1
Status: NEW
Severity: normal
Priority: P2
Component: POI Overall
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
Created attachment 34668
--> https://bz.apache.org/bugzilla/attachment.cgi?id=34668&action=edit
The image shows the error that is seen while opening the pptx file
Apache poi - 3.13 is being used to generate a pptx file. The generated file
cannot be opened: when attempted to open, the file displays that it has a
problem with the content and offers an option to "repair". After clicking on
"repair" a couple of times, the file does open up eventually.
XSLFTableCell cell
XSLFTextParagraph p
XSLFTextRun line
XSLFTable tbl = slide.createTable();
tbl.setAnchor(new Rectangle(X, Y, WIDTH, HEIGHT));
XSLFTableRow headerRow = tbl.addRow();
headerRow.setHeight(45);
//Loop through the data collection and populate rows and columns.
for(int i = 0; i < numberOfCols; i++) {
XSLFTableCell th = headerRow.addCell();
p = th.addNewTextParagraph();
p.setTextAlign(TextAlign.CENTER);
line = p.addNewTextRun();
.....}
for (int item=0; item < 8; item++)
{
XSLFTableRow itemRow = tbl.addRow();.....}
//finally write the file
File pptFile = File.createTempFile("fileName", ".ppt")
FileOutputStream out = new FileOutputStream(pptFile)
ppt.write(out)
out.close()
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]