Solved

Directory/folder utility

Posted on 2007-04-11
3
155 Views
Last Modified: 2010-04-18
Is there a utility out there that can go through a drive/directories and list the name of directories, the total size of the directories and other attribute such as last modified or even what type files are within the directories, etc?
0
Comment
Question by:bigd563
3 Comments
 
LVL 30

Expert Comment

by:LauraEHunterMVP
ID: 18890289
Take a look at DumpSec (www.somarsoft.com), a utility which we often recommend for requests like this one.

You can also use your own VBScripts to dump out the information you're looking for; take a look at the sample scripts on the Technet Script Repository to get you started: http://www.microsoft.com/technet/scriptcenter/scripts/default.mspx?mfr=true
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18890300

Hello bigd563,
Something like this will do it...


'FindAllFiles.vbs
Dim objFSO : Set objFSO = CreateObject("Scripting.FileSystemObject")
Dim objOutput:Set objOutputFile = objFSO.CreateTextFile("C:\Output.log")
Dim dtOld

strSourceFolder = "C:\Testing" 'starting folder...will recurse downward from here

ProcessFolder objFSO.GetFolder(strSourceFolder)

With objOutput
  .WriteLine
  .WriteLine "Process completed at " & Now
  .WriteLine "==========================="
  .Close
End With

Set objOutputFile = Nothing
Set objFSO = Nothing
wscript.quit


Sub ProcessFolder(strSource)
  ProcessFiles strSource
  For Each fld In strSource.SubFolders
    ProcessFolder fld
  Next
End Sub

Sub ProcessFiles(strSrc)
  For Each file In strSrc.Files
    objOutput.WriteLine objFSO.GetExtensionName(file.name) & "," & file & "," & file.size & "," & file.datecreated & "," & file.datelastmodified & "," & file.datelastaccessed
  End If
  Next
End Sub

~sirbounty
0
 
LVL 70

Accepted Solution

by:
KCTS earned 500 total points
ID: 18890662
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Join & Write a Comment

So you have two Windows Servers and you have a directory/folder/files on one that you'd like to mirror to the other?  You don't really want to deal with DFS or a 3rd party solution like Doubletake. You can use Robocopy from the Windows Server 200…
I guess it is not common knowledge to most Wintel engineers/administrators: If you have an SNMP-based monitoring system in your environment (and it's common to have SNMP or Syslog) it's reasonably easy to enable monitoring of the Windows Event logs,…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now