File all directories : File « Win32 « Perl






File all directories

    


use File::Find;
use Win32::File;

&File::Find::find(\&wanted,"C:\\httpd", "C:\\testing");
sub wanted{
      (Win32::File::GetAttributes($_,$attr)) &&
      ($attr & DIRECTORY) &&
      print "$File::Find::name\n";
}

   
    
    
    
  








Related examples in the same category

1.To change the attributes, you can call SetAttributes.
2.File system
3.Current directory
4.Setting file attributes on Windows