It's not a secret anymore!
The moose likes JSP and the fly likes read jar from c: Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "read jar from c:" Watch "read jar from c:" New topic

read jar from c:

Gopi Rajesh

Joined: Dec 09, 2003
Posts: 6
Hi all,
I am new to jsp. I use jbuilder for my swing application. In Jbuilder, required libraries, I specified c:\program files\open office \ xx.jar.
Its working.
In jsp I want to read the .jar file from the path c:\program files\open office\ xx.jar. I dont know how to read jar from c:.

Please help me regarding this.

Thanks in advance

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63873

In a web application you customarily place the jar files either in the servlet container's library folder (for jars that will be shared across multiple web apps) or the WEB-INF/lib folder of your web app.

[Asking smart questions] [About Bear] [Books by Bear]
Gopi Rajesh

Joined: Dec 09, 2003
Posts: 6
Hi Bear,

you are right. But my program will run when it reads jar files from c:\program files\open office\ xx.jar. I tried to put all my required open office jar in web-inf\lib folder.

I am getting the error like this access denied (java.util.PropertyPermission read)

at Source)

at Source)

at java.lang.SecurityManager.checkPermission(Unknown Source)

at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)

at java.lang.System.getProperty(Unknown Source)


at Document.OpenOfficeViewletPane.initialise_Office(

at Document.OpenOfficeViewletPane.<init>(

at Document.DocumentViewlet.createWriterBlankDoc(

at Document.DocumentViewlet.displayDocument(

at Document.DocumentViewlet.displayData(

at Document.DocumentViewlet.displayViewlet(

at Document.DocumentDesigner.createNestedComponent(

at Document.DocumentDesigner.setNonVisualRecord(

at GUI.Graph.NestedGraphlet.displaySimpleComponents(

at GUI.Graphlet.uponRecordsRetreival(

at GUI.Graphlet.prodDataAvailable(

at GUI.Graph.NestedGraphlet.prodDataAvailable(


at java.awt.event.InvocationEvent.dispatch(Unknown Source)

at java.awt.EventQueue.dispatchEvent(Unknown Source)

at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)

at java.awt.EventDispatchThread.pumpEvents(Unknown Source)

at java.awt.EventDispatchThread.pumpEvents(Unknown Source)

at Source)

This is my problem. Anyway Thanks a lot for your response.


Julian Kennedy
Ranch Hand

Joined: Aug 02, 2004
Posts: 823

That doesn't look like a problem with the JAR. It's telling you that you don't have permission to access the system property. Is this at the client or server side? It's likely that a setting in your policy file is restricting access.

Gopi Rajesh

Joined: Dec 09, 2003
Posts: 6
Thanks for your response. This is my problem. How do I give permission to enable this option.

Thanks in advance

I agree. Here's the link:
subject: read jar from c:
It's not a secret anymore!