This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes how to read text file in zip file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "how to read text file in zip file" Watch "how to read text file in zip file" New topic
Author

how to read text file in zip file

sheng zhong
Greenhorn

Joined: Nov 23, 2006
Posts: 20
Hi All, I am gonna read some plain text file in zip file.The development enviroment is java eclipse. I wonder how to do that, is there any sample code I can refer? I search online but nothing found.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41060
    
  43
This example shows how to retrieve a file from within a ZIP archive.


Ping & DNS - my free Android networking tools app
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14074
    
  16

Java has support for ZIP files in the standard API. See the documentation of the package java.util.zip.

For examples, see: http://exampledepot.com/egs/java.util.zip/pkg.html


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
sheng zhong
Greenhorn

Joined: Nov 23, 2006
Posts: 20
Hey, thanks, that's really help!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to read text file in zip file
 
Similar Threads
How to write zip files into another zip file..?
download zip file with servlet : Bad CRC
How to read a file from which is stored in zip file ?
Loading images from zip files
JAR Problems