use strict; use Win32::DirSize; my $Result = dir_size( "C:\\TEMP", my $DirInfo, # this stores the directory information );