Mark Butcher wrote:The only thing I know is to delete one single file as follows :...
Actually, that won't just delete files; it'll delete directories as well (or it
may do), because a
File can be either an actual file OR a directory.
I recommend that you study the
File class documentation (java.io.File (←click)) carefully, because all the methods you need are contained in it. A look at the
tutorials probably wouldn't go amiss either, because it also covers some of the
java.nio.file package features (new with version 7) - in particular the
Files class.
HIH
Winston