directory help needed

  • Thread starter Thread starter Dave Harris
  • Start date Start date
D

Dave Harris

Once upon a time, a programmer could send the entire directory tree to a
text file by using the command:
dir c: >directory.txt

Is there a way to do this in VB.NET? I need the text file to contain all of
the directories, subdirectories, and files along with file size and total
directory size. Thanks in advance!!!!

Dave
 
* "Dave Harris said:
Once upon a time, a programmer could send the entire directory tree to a
text file by using the command:
dir c: >directory.txt

Is there a way to do this in VB.NET? I need the text file to contain all of
the directories, subdirectories, and files along with file size and total
directory size. Thanks in advance!!!!

There is no built-in method to do that. Have a look at the classes in
the 'System.IO' namespace, namely 'Directory', 'File', 'DirectoryInfo'
and 'FileInfo' and the 'StreamWriter' for writing the information to the
file.
 
You could use shell and run that same command. It still works
 
Hi Herfried,

One of your specialities the Shell class and than Mike says it can

:-))

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top