|
-
May 14th, 2013, 08:05 PM
#1
Thread Starter
Banned
get all directories in all o/s
i need help listing all diretories in
winxp
vista / 7/ 8
should show all folders only thanks.
how do i use if statement
if windows xp then show directories
if vista then show directories
if win 7 then show dir
bec folder path and names are different so i thihnk if statement is good for me but need example
Last edited by ladoo; May 14th, 2013 at 08:09 PM.
-
May 14th, 2013, 08:26 PM
#2
Re: get all directories in all o/s
Do you mean all directories on a single drive or throughout the whole operating system?
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
May 14th, 2013, 09:19 PM
#3
Re: get all directories in all o/s
I can't think of any reason that you would need to check the OS. There are differences in the directory structure from XP to Vista of course but if you are listing all directories this would not be an issue.
If you want to use VB code then you would use the Dir$() function recursively or optionally you could use the FSO
There are some folders that will deny access and may throw an error so you have to account for that.
-
May 15th, 2013, 02:57 AM
#4
Thread Starter
Banned
Re: get all directories in all o/s
whole operating system , shared folder / my documents / pictures / music / windows / and system32
i need to first list all directory , second task copy files to were ever i want
-
May 15th, 2013, 04:50 AM
#5
Junior Member
Re: get all directories in all o/s
Command Promt..
DIR *.* /S /AD>C:\MYDIRLIST.txt
writes a list of all folders to a text file..
There are ways to Manipulate the list But i forget the syntax. 
OR..
tree /a>c:\DirTree.txt
tree /a /f>c:\TreeWithFile.txt
Last edited by electrodoc; May 15th, 2013 at 05:00 AM.
There are 10 Different People In The World... Those Who Understand Binary And Those Who Don't...

-
May 15th, 2013, 05:00 AM
#6
Re: get all directories in all o/s
You can probably find the code to do what you want in the project here.
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
May 15th, 2013, 07:16 AM
#7
Thread Starter
Banned
Re: get all directories in all o/s
it shows browse for folder , i want to show all list like tht yeh but in listbox something
-
May 15th, 2013, 07:27 AM
#8
Re: get all directories in all o/s
Against my better judgement... I'm going to allow myself to get sucked into this thread for a moment...
what you're looking for is the Dir() function
I'll leave it to you to figure the details.
-tg
-
May 15th, 2013, 10:25 AM
#9
Thread Starter
Banned
Re: get all directories in all o/s
-
May 15th, 2013, 11:53 AM
#10
Re: get all directories in all o/s
Sigh..... so the problem is solved ?
-
May 15th, 2013, 07:39 PM
#11
Re: get all directories in all o/s
 Originally Posted by ladoo
it shows browse for folder , i want to show all list like tht yeh but in listbox something
You didn't search though the whole code.
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|