in reply to 'Permission Denied' error from File::Find

$directory = 'c:\my_directory';

Should be:
$directory = 'c:\\my_directory'; # or $directory = 'c:/my_directory';

Update: This is not the problem it seems. So the problem should be elsewhere.

Replies are listed 'Best First'.
Re: Re: 'Permission Denied' error from File::Find
by jdporter (Paladin) on Feb 11, 2004 at 03:49 UTC
    Are you sure? It seemed to work for me:
    C:\>perl my $x = 'c:\my_dir'; print "'$x'\n"; ^Z 'c:\my_dir' C:\>perl -v This is perl, v5.8.0 built for MSWin32-x86-multi-thread

    jdporter
    The 6th Rule of Perl Club is -- There is no Rule #6.

Re: Re: 'Permission Denied' error from File::Find
by arden (Curate) on Feb 11, 2004 at 05:53 UTC
    Roger, that should work fine because witandhumor is using apostrophes (single ticks). These are all the same thing on Win32:

    $directory = 'c:\my_directory'; $directory = 'c:/my_directory'; $directory = "c:\\my_directory"; $directory = "c:/my_directory";

    Basically, if you're going to need to expand any variables, you need to use quotes (double ticks), but for literals it's easier to use apostrophes.