https://issues.apache.org/bugzilla/show_bug.cgi?id=49370
Summary: Can't save out .xlsx with conditional formatting.
Product: POI
Version: 3.6
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: major
Priority: P2
Component: XSSF
AssignedTo: [email protected]
ReportedBy: [email protected]
Created an attachment (id=25507)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=25507)
xlsx that shows the issue.
Similar to ticket 48494
Given the following snippet in a J2EE app, using POI 3.6 20091214:
String realPath = getServletContext().getRealPath("/WEB-INF/Book1.xlsx");
InputStream inp = new FileInputStream(realPath);
Workbook wb = WorkbookFactory.create(inp);
wb.createSheet("new sheet");
// Write the output to a file
realPath = getServletContext().getRealPath("/WEB-INF/Book1_out.xlsx");
FileOutputStream fileOut = new FileOutputStream(realPath);
wb.write(fileOut);
fileOut.close();
this dies on the .write() call with:
javax.servlet.ServletException: java.lang.NoClassDefFoundError:
org/openxmlformats/schemas/spreadsheetml/x2006/main/CTDxfs$1
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:855)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:784)
org.apache.jsp.About_jsp._jspService(About_jsp.java:112)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:387)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
commenting out the .createSheet() avoids the error, avoiding conditional
formatting avoids the error. (Cell E1 contains the conditional formatting in
the attachment.)
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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]