By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,657 Members | 751 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,657 IT Pros & Developers. It's quick & easy.

getting sub-folders and their sub-folders and so on

P: n/a
Does anyone know an easy way to get all of the folders and their sub-folders
and their sub-folders and so on? I need to get all of the folders and their
paths from an inputted parent folder textbox. I need to put this into a
string array variable like:
c:
c:\windows
c:\test
c:\windows\1
c:\windows\1\a
c:\test\6
The problem is I am going to be using this tool on different folder
structures and don't know how deep the folders are going to be and need this
to dynamically loop until it picks up all the sub-folders.

Thanks for your help...........Jason
Aug 27 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi,

There is no inbuilt way to do this. Check out these:

http://www.stillhq.com/dotnet/000003.html

"Recursive Listing of Directories" in
http://www.aspheute.com/english/20000804.asp

"Jason Steeves" <Ja**********@discussions.microsoft.com> wrote in message
news:6E**********************************@microsof t.com...
Does anyone know an easy way to get all of the folders and their sub-folders
and their sub-folders and so on? I need to get all of the folders and their
paths from an inputted parent folder textbox. I need to put this into a
string array variable like:
c:
c:\windows
c:\test
c:\windows\1
c:\windows\1\a
c:\test\6
The problem is I am going to be using this tool on different folder
structures and don't know how deep the folders are going to be and need this
to dynamically loop until it picks up all the sub-folders.

Thanks for your help...........Jason
Aug 28 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.