Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Counting the Number of Folders Not Files.
I can count the number of files in a directory by using
foundfiles.count property, but what would I use to count the number of folders(directories)? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Counting the Number of Folders Not Files.
or without the reference
MsgBox CreateObject("Scripting.FileSystemObject").GetFold er("C:\Temp").SubFolders.C ount -- HTH Bob Phillips "Chip Pearson" wrote in message ... Ron, Set a reference to the Windows Scripting Runtime library and use code such as the following: Dim FSO As New Scripting.FileSystemObject MsgBox FSO.GetFolder("C:\Temp").SubFolders.Count -- Cordially, Chip Pearson Microsoft MVP - Excel www.cpearson.com "Ron" wrote in message ... I can count the number of files in a directory by using foundfiles.count property, but what would I use to count the number of folders(directories)? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
.TMP files are corrupting my folders | Excel Discussion (Misc queries) | |||
Opening Files/Folders | Excel Discussion (Misc queries) | |||
Drive - Folders - Files | Excel Discussion (Misc queries) |