File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
    Bookmark Topic Watch Topic
  • New Topic

Jar files & JarOutputStream

 
Ayad Hindi
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hello all !!
I have written an application that is contained in a jar. The application needs to access a properties file in the jar, modify the file, and then save it back to the jar.
The problem that I am getting is that each time a save the file to the jar, it creates a brand new jar with the same name as the one I had, and therefore I loose all my .class files and manifest.
So the question is can you add new files (or modified ones) to an existing jar, using the java.util.jar package? If not, is there any other package that would allow me to do so?
Help would be much appreciated. Thanks...
Ayad Hindi
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please don't repeat the same post in different forums - it may waste people's time if they compose a reply for something that is already answered elsewhere. I'm closing this thread - any followups can go here.
 
I agree. Here's the link: http://aspose.com/file-tools
    Bookmark Topic Watch Topic
  • New Topic