John Barrat wrote:
> Have used SHFileOperation to do the deletin and record the progress -
> works great - thanks for the help.
>
> Now for a follow on question.
>
> Currently I am using the FindFirst/FindNext functions to obtain a list of
> files in a directory an have written additional code to recurse through
> any
> the subdirectories.  Is there a function (similar the the SHFileOperation)
> which will do this already?

ShFileOperation understands wildcards. It can also delete entire directory
hierarchies (as opposed to RemoveDirectory, which requires directories to
be empty). So you shouldn't need to build up a list of all the files you
want to delete.

Anyway, Delphi has nothing built in. The JCL has some file-enumeration
tools, though. Look in the JclFileUtils unit.

-- 
Rob


_______________________________________________
Delphi mailing list -> [email protected]
http://www.elists.org/mailman/listinfo/delphi

Reply via email to