You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by Antony Bowesman <ad...@teamware.com> on 2008/09/17 06:39:55 UTC
POIFSFileSystem.getRoot - NoSuchMethodError
Just can work out what's wrong here - I know it's probably a classpath issue,
but I'm getting
java.lang.NoSuchMethodError:
org.apache.poi.poifs.filesystem.POIFSFileSystem.getRoot()Lorg/apache/poi/poifs/filesystem/DirectoryNode
from fsys.getRoot() during
POIFSFileSystem fsys = new POIFSFileSystem(in);
DocumentEntry headerProps =
(DocumentEntry)fsys.getRoot().getEntry("WordDocument");
As far as I can see I have
964,285 poi-3.0.2-FINAL-20080204.jar
59,411 poi-contrib-3.0.2-FINAL-20080204.jar
888,864 poi-scratchpad-3.0.2-FINAL-20080204.jar
and I can step into the "new POIFSFileSystem()" in the debugger in Eclipse. If
I remove the poi-3.0.2-FINAL-20080204.jar I get ClassNotFoundException in the
new(), but as soon as I try to step into the fsys.getRoot() it throws the above
Exception.
It's running inside Tomcat.
Any ideas?
Antony
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
Re: POIFSFileSystem.getRoot - NoSuchMethodError
Posted by hdamle <hd...@datafrond.com>.
/Core POI came from
file:/C:/ptc/Windchill_9.1/Apache/poi-3.7/poi-3.7.jar!/org/apache/poi/poifs/filesystem/POIFSFileSystem.class
/
The above line is my Core PoI Path and it's showing I am using library
version 3.7. The below indicates the error I am getting: How to resolve this
issue?
/Exception in thread "main" java.lang.NoSuchMethodError:
org.apache.poi.poifs.filesystem.POIFSFileSystem.getRoot()Lorg/apache/poi/poifs/filesystem/DirectoryEntry
;
/
--
View this message in context: http://apache-poi.1045710.n5.nabble.com/POIFSFileSystem-getRoot-NoSuchMethodError-tp2332188p4558892.html
Sent from the POI - Dev mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
Re: POIFSFileSystem.getRoot - NoSuchMethodError
Posted by Antony Bowesman <ad...@teamware.com>.
> Try following the suggestions in q1 of the FAQ:
> http://poi.apache.org/faq.html#faq-N10006
>
> That ought to help you with your classpath issue
Thanks for that pointer Nick - it showed the classes were correctly coming from
poi-3.0.2-FINAL-20080204.jar, but I recompiled the class using the
POIFSFileSystem and the problem went away - I guess it must have been built with
some older version of POI.
Thanks
Antony
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
Re: POIFSFileSystem.getRoot - NoSuchMethodError
Posted by Nick Burch <ni...@torchbox.com>.
On Wed, 17 Sep 2008, Antony Bowesman wrote:
> Just can work out what's wrong here - I know it's probably a classpath issue,
> but I'm getting
>
> java.lang.NoSuchMethodError:
> org.apache.poi.poifs.filesystem.POIFSFileSystem.getRoot()Lorg/apache/poi/poifs/filesystem/DirectoryNode
Try following the suggestions in q1 of the FAQ:
http://poi.apache.org/faq.html#faq-N10006
That ought to help you with your classpath issue
Nick
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org