This seems to work:
use strict; use warnings; use File::Monitor; my $monitor = File::Monitor->new(); $monitor->watch ( { name => 'C:/whatever', # or whatever callback => \&print_new, files => 1, } ); while ( 1 ) { $monitor->scan; sleep 10; # or however long you need } sub print_new { print join "\n", pop->files_created; print "\n"; }
In reply to Re: Please HELP! FILE::MONITOR Configuration
by Not_a_Number
in thread Please HELP! FILE::MONITOR Configuration
by jdlev
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |