Hello... 
        This script works fine on Unix: 

#!/usr/local/bin/perl
use warnings;
use strict;
my $dir = "/usr/home/admin";
my @files = glob ("$dir/*");
print @files;


But this script doesn't do right in Windows: 

use warnings; 
use strict; 
my $dir = "E:\\Documents and Settings\\cmcmahon\\Desktop"; 
print "$dir\n";  
my @files = glob( "$dir\\*");
print @files; 

The "print "$dir\n"" statement works fine, but the "print @files" statement
yields the value "E:./Documentsand".  Can someone explain what Windows needs
here?    

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to