in reply to Reg Ex : an odd error...

Not really sure why this error came up. But if I change
@bannedF = ("c:\\win32app\\toolkit", "c:\\winnt", "C:\\WINNT\\system32", "d:\\perl", "d:\\brossad");
to
@bannedF = qw( c:/win32app/toolkit c:/winnt C:/WINNT/system32 d:/perl +d:/brossad );
it works.

Also my $folder = "c:\TEMP\sdfs"; should be my $folder = "c:\\TEMP\\sdfs"; or my $folder = 'c:\TEMP\sdfs';

Update: Looking at my Perl reference it looks like it is interpreting \p as a property.