• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to delete a zipped folder

 
kayanaat sidiqui
Ranch Hand
Posts: 122
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Suppose there is a zipped folder name "myZip.zip".

It contains two text files let say text1.txt and text2.txt.

What i need is to delete the "myZip.zip".


How to do that?

Thanks,
Kaya.
 
Rob Spoor
Sheriff
Posts: 20837
68
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A zipped folder is actually a simple ZIP file, so File's delete() method should do the trick.
 
kayanaat sidiqui
Ranch Hand
Posts: 122
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Rob.

Previously i tried with this. But did some mistakes thts why i did not get result.

Anyways thanks a lot. I did it.
 
my overalls have superpowers - they repel people who think fashion is important. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!