Link to home
Start Free TrialLog in
Avatar of AlHal2
AlHal2Flag for United Kingdom of Great Britain and Northern Ireland

asked on

Get size of each directory on each mapped drive

There are thousands of directories on this machine.  Sometimes a huge file gets added somewhere and it's very difficult to find where it is.
Sometimes house keeping doesn't work.
Both of these things can cause a drive to run out of space.
Please can I have some VB.Net 2010 (windows) code to get the size of every directory on all drives.  If I can call a batch file to do the same thing that is fine.  I want to avoid using 3rd party software.

eg

C:\temp  3MB
   C:\temp\subDirA 2MB
   C:\temp\SubDirB 1MB
Avatar of Éric Moreau
Éric Moreau
Flag of Canada image

Avatar of AlHal2

ASKER

I need it to be recursive through all the drives and subfolders on each drive.
ASKER CERTIFIED SOLUTION
Avatar of Éric Moreau
Éric Moreau
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of AlHal2

ASKER

Thanks.
Avatar of AlHal2

ASKER

Thanks.