I'm doing my best but having a lot of trouble understanding the 
documentation for File::Find.  After seeing a number of people being 
yelled at for trying to reinvent the wheel by writing their own 
functions, I'm resigned to throwing up my hands and begging for someone 
to hold my hand through a concrete example, hopefully showing how the 
pre\post\process functions are invoked and can be used.

Also, I'm wondering if there's a way to implement a mechanism that times 
the execution of the script.

________________________

# Recurse a defined directory summarising folder information based on
# file type and then provide a way to call other functions to perform 
# actions on any of those files.

use strict;
use warnings;
use File::Find;

find(\&wanted, "C:/SomeFolder");

sub wanted {
        my $dir_count = 0;
        if (-d $_) {
                print ".";
                $dir_count++;
                
# rest of code that finishes with print statements something like:
# "There are $file_total files in $dir_count directories."
# "The folder \"($folder_name)\" contains $files_in_folder .TXT files."

________________________

Comments, questions and complaints all welcomed.                

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to