poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhaskar <bhaskarb...@gmail.com>
Subject Re:org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
Date Wed, 29 Jun 2011 10:28:06 GMT
Hi,
  I am reading the data from xlsx using apachi poi. And i am getting the
following below Exception.The following jar files I put the following jars
in the classpath=poi-3.5-beta3 ,

xmlbeans-2.4.0,poi-ooxml-schemas-3.7-20101029,poi-ooxml-3.7,poi-ooxml-3.6-20091214,poi-3.5-beta5-20090219,poi-3.5-beta3,ooxml-schemas-1.0,dom4j-1.6.1.
can you pleasse any one help me.

Thanks in advance

Thanks &Regards
Bhaskar




org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:61)
        at
org.apache.poi.POIXMLDocumentPart.read(POIXMLDocumentPart.java:277)
        at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:186)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
82)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
98)
        at MainReEX.ReadSheet(MainReEX.java:18)
        at MainReEX.main(MainReEX.java:49)
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method

        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstruc
orAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delegating
onstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:59)
        ... 6 more
Caused by: java.lang.NoClassDefFoundError:
javax/xml/stream/XMLStreamException
        at java.lang.Class.getDeclaredMethods0(Native Method)
        at java.lang.Class.privateGetDeclaredMethods(Class.java:2365)
        at java.lang.Class.getMethod0(Class.java:2611)
        at java.lang.Class.getMethod(Class.java:1579)
        at org.apache.xmlbeans.XmlBeans.buildMethod(XmlBeans.java:174)
        at org.apache.xmlbeans.XmlBeans.buildNodeMethod(XmlBeans.java:195)
        at
org.apache.xmlbeans.XmlBeans.buildNodeToCursorMethod(XmlBeans.java:2
2)
        at org.apache.xmlbeans.XmlBeans.<clinit>(XmlBeans.java:131)
        at
org.openxmlformats.schemas.drawingml.x2006.main.ThemeDocument$Factor
.parse(Unknown Source)
        at org.apache.poi.xssf.model.ThemesTable.<init>(ThemesTable.java:39)
        ... 11 more

F:\Bhaskar\XXXXX>java MainReEX
Error0
org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:61)
        at
org.apache.poi.POIXMLDocumentPart.read(POIXMLDocumentPart.java:277)
        at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:186)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
82)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
98)
        at MainReEX.ReadSheet(MainReEX.java:18)
        at MainReEX.main(MainReEX.java:49)
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method

        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstruc
orAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delegating
onstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:59)
        ... 6 more
Caused by: java.lang.NoClassDefFoundError:
javax/xml/stream/XMLStreamException
        at java.lang.Class.getDeclaredMethods0(Native Method)
        at java.lang.Class.privateGetDeclaredMethods(Class.java:2365)
        at java.lang.Class.getMethod0(Class.java:2611)
        at java.lang.Class.getMethod(Class.java:1579)
        at org.apache.xmlbeans.XmlBeans.buildMethod(XmlBeans.java:174)
        at org.apache.xmlbeans.XmlBeans.buildNodeMethod(XmlBeans.java:195)
        at
org.apache.xmlbeans.XmlBeans.buildNodeToCursorMethod(XmlBeans.java:2
2)
        at org.apache.xmlbeans.XmlBeans.<clinit>(XmlBeans.java:131)
        at
org.openxmlformats.schemas.drawingml.x2006.main.ThemeDocument$Factor
.parse(Unknown Source)
        at org.apache.poi.xssf.model.ThemesTable.<init>(ThemesTable.java:39)
        ... 11 more

F:\Bhaskar\XXXXX>set classpath=

F:\Bhaskar\XXXXX>set
classpath=F:\Bhaskar\NewJars\xmlbeans-2.4.0.jar;F:\Bhaskar
NewJars\xmlbeans-2.3.0.jar;F:\Bhaskar\NewJars\poi-ooxml-schemas-3.7-20101029.ja
;F:\Bhaskar\NewJars\poi-ooxml-schemas-3.6-20091214.jar;F:\Bhaskar\NewJars\poi-o
xml-3.7.jar;F:\Bhaskar\NewJars\poi-ooxml-3.6-20091214.jar;F:\Bhaskar\NewJars\po
-3.7
(1).jar;F:\Bhaskar\NewJars\poi-3.5-beta5-20090219.jar;F:\Bhaskar\NewJars\p
i-3.5-beta3.jar;F:\Bhaskar\NewJars\ooxml-schemas-1.0.jar;F:\Bhaskar\NewJars\dom
j-1.6.1.jar;.;%classpath%;

F:\Bhaskar\XXXXX>javac MainReEX.java

F:\Bhaskar\XXXXX>java MainReEX
Error0
org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:61)
        at
org.apache.poi.POIXMLDocumentPart.read(POIXMLDocumentPart.java:277)
        at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:186)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
82)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
98)
        at MainReEX.ReadSheet(MainReEX.java:18)
        at MainReEX.main(MainReEX.java:49)
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method

        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstruc
orAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delegating
onstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:59)
        ... 6 more
Caused by: java.lang.NoClassDefFoundError:
javax/xml/stream/XMLStreamException
        at java.lang.Class.getDeclaredMethods0(Native Method)
        at java.lang.Class.privateGetDeclaredMethods(Class.java:2365)
        at java.lang.Class.getMethod0(Class.java:2611)
        at java.lang.Class.getMethod(Class.java:1579)
        at org.apache.xmlbeans.XmlBeans.buildMethod(XmlBeans.java:174)
        at org.apache.xmlbeans.XmlBeans.buildNodeMethod(XmlBeans.java:195)
        at
org.apache.xmlbeans.XmlBeans.buildNodeToCursorMethod(XmlBeans.java:2
2)
        at org.apache.xmlbeans.XmlBeans.<clinit>(XmlBeans.java:131)
        at
org.openxmlformats.schemas.drawingml.x2006.main.ThemeDocument$Factor
.parse(Unknown Source)
        at org.apache.poi.xssf.model.ThemesTable.<init>(ThemesTable.java:39)
        ... 11 more

F:\Bhaskar\XXXXX>javac MainReEX.java

F:\Bhaskar\XXXXX>java MainReEX
Error0
org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:61)
        at
org.apache.poi.POIXMLDocumentPart.read(POIXMLDocumentPart.java:277)
        at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:186)
        at
org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:
89)
        at MainReEX.ReadSheet(MainReEX.java:18)
        at MainReEX.main(MainReEX.java:49)
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method

        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstruc
orAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delegating
onstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at
org.apache.poi.xssf.usermodel.XSSFFactory.createDocumentPart(XSSFFac
ory.java:59)
        ... 5 more
Caused by: java.lang.NoClassDefFoundError:
javax/xml/stream/XMLStreamException
        at java.lang.Class.getDeclaredMethods0(Native Method)
        at java.lang.Class.privateGetDeclaredMethods(Class.java:2365)
        at java.lang.Class.getMethod0(Class.java:2611)
        at java.lang.Class.getMethod(Class.java:1579)
        at org.apache.xmlbeans.XmlBeans.buildMethod(XmlBeans.java:174)
        at org.apache.xmlbeans.XmlBeans.buildNodeMethod(XmlBeans.java:195)
        at
org.apache.xmlbeans.XmlBeans.buildNodeToCursorMethod(XmlBeans.java:2
2)
        at org.apache.xmlbeans.XmlBeans.<clinit>(XmlBeans.java:131)
        at
org.openxmlformats.schemas.drawingml.x2006.main.ThemeDocument$Factor
.parse(Unknown Source)
        at org.apache.poi.xssf.model.ThemesTable.<init>(ThemesTable.java:39)

--
View this message in context: http://apache-poi.1045710.n5.nabble.com/Re-org-apache-poi-POIXMLException-java-lang-reflect-InvocationTargetException-tp4534706p4534706.html
Sent from the POI - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org


Mime
View raw message