You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2011/06/01 16:52:03 UTC
DO NOT REPLY [Bug 51308] New: NoClassErrorFound when parse basic
xslx file
https://issues.apache.org/bugzilla/show_bug.cgi?id=51308
Bug #: 51308
Summary: NoClassErrorFound when parse basic xslx file
Product: POI
Version: 3.7
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: blocker
Priority: P2
Component: XSSF
AssignedTo: dev@poi.apache.org
ReportedBy: dhj123456@gmail.com
Classification: Unclassified
The xslx is microsoft excel 2007 format, and only have one cell "Hello",
Code 1:
XSSFWorkbook wb = new XSSFWorkbook(new
FileInputStream("hello.xslx"));
XSSFSheet sheet = wb.getSheetAt(0);
System.out.println(sheet.getLastRowNum());
Code 2:
Workbook wb = WorkbookFactory.create(new
FileInputStream("hello.xslx"));
Sheet sheet = wb.getSheetAt(0);
System.out.println(sheet.getLastRowNum());
Error:
Caused by: java.lang.NoClassDefFoundError:
org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTOneCellAnchor
at java.lang.J9VMInternals.verifyImpl(Native Method)
at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:67)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:521)
at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createUnattachedNode(SchemaTypeImpl.java:1859)
at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createTypeStoreUser(SchemaTypeImpl.java:1805)
at org.apache.xmlbeans.impl.store.Xobj.setStableType(Xobj.java:1390)
at org.apache.xmlbeans.impl.store.Cur.setType(Cur.java:2497)
at org.apache.xmlbeans.impl.store.Cur.setType(Cur.java:2482)
at org.apache.xmlbeans.impl.store.Locale.autoTypeDocument(Locale.java:352)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:1273)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:1257)
at
org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase.parse(SchemaTypeLoaderBase.java:345)
at
org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTDrawing$Factory.parse(Unknown
Source)
at org.apache.poi.xssf.usermodel.XSSFDrawing.<init>(XSSFDrawing.java:80)
... 11 more
--
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: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
Re: Suppress extraction of some/all numeric fields in XLS documents
?
Posted by Nick Burch <ni...@alfresco.com>.
On Fri, 3 Jun 2011, Chris Bamford wrote:
> Say we have a percentage 56%
>
> In a spreadsheet display this shows as
>
> 56%
>
> The text extraction gives us
>
> 0.5590614886731392
You probably just want to apply the formatting rules to the cell when you
extract it. org.apache.poi.ss.usermodel.DataFormatter should help here
Nick
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
Suppress extraction of some/all numeric fields in XLS documents ?
Posted by Chris Bamford <cb...@mimecast.com>.
Hi
Is it possible to suppress the extraction of some/all numeric fields in XLS documents via Aperture/POI?
Sometimes the string equivalents of numeric values produce weird strings which can confuse some of our processes. For example,
Say we have a percentage 56%
In a spreadsheet display this shows as
56%
The text extraction gives us
0.5590614886731392
Unfortunately this number resembles an international telephone number or even a credit card number and could generate a false positive when matching.
Any ideas?
Thanks,
- Chris
DO NOT REPLY [Bug 51308] NoClassErrorFound when parse basic xslx
file
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51308
Nick Burch <ni...@alfresco.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID
--- Comment #1 from Nick Burch <ni...@alfresco.com> 2011-06-01 14:56:41 UTC ---
See the FAQ: http://poi.apache.org/faq.html#faq-N10025
--
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: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org