Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 08, 2016, 10:06:09 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: List all subfolders on multiple drives to text of csv  (Read 8442 times)

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
List all subfolders on multiple drives to text of csv
« on: August 27, 2013, 08:21:42 AM »

On multiple drives/partitions I have certain rootfolders, like x:\SomeRootFolderName\ with a lot of subfolders.
At regular intervals I create listings of the subfolder-names (not files..) including size, date/time, path and copy paste them into Excel.

Quite some click here, there select all, copy paste, browse down in Excel, then next drrive,  select/copy/paste etc.

Tried to find a tool/batch file that can do this.
Where I can edit/add the drives-folders myself and when running it generate a listing to clipboard, which i can paste into Excel?

Have looked at SMF
Thread: Create a file list from multiple folders  at  http://www.donationc...ex.php?topic=31520.0
but I think it can't generate a folderlisting.

Thanks!
=



4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,474
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #1 on: August 27, 2013, 08:52:41 AM »
SMF can do it:

Select the folder, and set it so it does folders only:
2013-08-27 23_39_42-SMF - Search my Files - v2.0 (2012-Feb-11).pngList all subfolders on multiple drives to text of csv

Click File-Information to collect, select DirGetSize & Count, then click Search
2013-08-27 23_40_16-SMF - Search my Files - v2.0 (2012-Feb-11).pngList all subfolders on multiple drives to text of csv

After it's done, select the result columns you want, first two are compulsary but that's OK atm, then press Show Report:
2013-08-27 23_40_34-Select Report Data Columns - SMF - Search my Files - v2.0 (2012-Feb-11).pngList all subfolders on multiple drives to text of csv

Select everything and right-click to bring up the menu:
2013-08-27 23_43_32-Search Report - SMF - Search my Files - v2.0 (2012-Feb-11).pngList all subfolders on multiple drives to text of csv

Select the info you want and click Export Data:
2013-08-27 23_44_15-SMF - Export to Clipboard.pngList all subfolders on multiple drives to text of csv

It's output to the clipboard as CSV data.

tomos

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 10,329
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #2 on: August 27, 2013, 08:54:24 AM »
I think you have Directory Opus (?)

menu: Tools > Print/Export folder listing

there's possibly better ways, but you could filter for a non-existant filetype (see shot), then you'll only get folders.

You have the options to just show current columns or select which you want.

Screenshot - 2013-08-27 , 15_50_29.pngList all subfolders on multiple drives to text of csv
Tom

4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,474
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #3 on: August 27, 2013, 08:56:19 AM »
Or yes, there's DOpus  :-[  :-\

tomos

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 10,329
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #4 on: August 27, 2013, 08:57:05 AM »
^SMF looks interesting :up:
(and - I'm not sure if they have Dopus)
Tom

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #5 on: August 27, 2013, 09:49:50 AM »
Yes, I am using Opus, but there I have to select each drive and copy paste them into Excel, removing headers, bla bla.
Directory Opus (as far as I know) sofar does not support, say F:\Folder1; G:\Folder2; H:\Folder3  etc.  (so it is one-by-one)

@4wd: SMF Yes, I found it, the folder thing.
Regretfully, it converts sizes and dates a bit differently, e.g.
2012.11.07-15:47:48 results in 20121107154748

I think I will stick to Opus and accept the extra copy paste once in a while. Was hoping for a very simple solution.  :)

=
SnagIt-27082013 164547.png
=




skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,668
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #6 on: August 27, 2013, 10:09:41 AM »
Was hoping for a very simple solution.

How deep are you going into those root folders you mention?  One level?  Two?  All?

4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,474
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #7 on: August 27, 2013, 10:39:01 AM »
Regretfully, it converts sizes and dates a bit differently, e.g.
2012.11.07-15:47:48 results in 20121107154748

A logical format in a constantly increasing number - makes it really easy to sort data :)

However, since this is going into Excel I would have thought that a simple data format conversion on the column would fix that - something Excel should be more than capable of doing.

At least with SMF you can do all folders across all drives at once.

rjbull

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 2,927
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #8 on: August 27, 2013, 03:00:26 PM »
You might get some mileage from the Unix "LS" command.  A port of the brute command line version is included GNU utilities for Win32 (UnxUtils.zip), but I don't think it does CSV natively.  However, there's a WinGUI version of LS that does.  It's been mentioned on DC numerous times, including:
A minor problem is that this LS doesn't exit cleanly, it appears to crash on exit!  But it still works well.

4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,474
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #9 on: August 27, 2013, 09:40:55 PM »
NOTE: I don't use Excel, I have Softmaker Office which has PlanMaker but I don't see this being that different.

Further to the import into Excel, all fields are Text with the exception of size which is Number:

This is the data output by SMF with a little formatting:

2013-08-28 12_37_00-PlanMaker - [Clipboard_20130828.pmd].png

To get it after import:

For the date:
2013-08-28 12_41_12-Cell.png

For the size:
2013-08-28 12_41_30-Cell.png

Another note, I use a spreadsheet program on average, once every 5 years - so there's probably a lot easier way to do this. eg. Make a worksheet template and import the data so it appears already formatted.
« Last Edit: August 27, 2013, 09:45:58 PM by 4wd »

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #10 on: August 28, 2013, 12:46:49 AM »
Was hoping for a very simple solution.

How deep are you going into those root folders you mention?  One level?  Two?  All?
@skwire: only 1 level, so:
x:\basefolder\subfolder1
x:\basefolder\subfolder2
x:\basefolder\subfolder3
etc.

like this:

=
Directory Opus-FolderPrint-28082013 072322.png
=

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #11 on: August 28, 2013, 01:09:42 AM »
@4wd - yes, thanks.
Indeed, one can adjust the cell-format/properties.
from default into ####-##=## ##-##-## (for the date)
and for the size in some other format.

I tried it again.

However, frankly speaking, bottom line Opus is much easier, quicker.
SMF launch takes much longer, it requires (a lot of) more clicks for this simple task.
Yes, SMF has much more features, etc.
However, in my case I won't be needing those.
In Excel it requires time for adjustments, bla bla.

So, bottomline, I think, in this case Opus, though not entirely meeting 'my demand' (multi folder print), is still the best solution.

=
SnagIt-28082013 080853.png
=

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #12 on: August 28, 2013, 01:21:01 AM »
You might get some mileage from the Unix "LS" command.  A port of the brute command line version is included GNU utilities for Win32 (UnxUtils.zip), but I don't think it does CSV natively.  However, there's a WinGUI version of LS that does.  It's been mentioned on DC numerous times, including:
A minor problem is that this LS doesn't exit cleanly, it appears to crash on exit!  But it still works well.

Thanks fo the tips. I have looked at these and some other tools.

Actually I think they are designed to list/print the contents, however, not just the folderpaths/foldernames/size/date-time

Sofar I have not found a tool that can do this job - I mean, in an easy/simple few clicks way.

=





rjbull

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 2,927
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #13 on: August 28, 2013, 02:33:53 PM »
Actually I think they are designed to list/print the contents, however, not just the folderpaths/foldernames/size/date-time

Branch of my directory tree:  WinGUI LS settings:
tree_branch.png                    WinGUI_LS_settings.png
LS output:
"[Path]","[Folder name]","[Save date]","[Size]"
"C:\Users\R.J. Bull\Junk\","CIS_Work","2009-09-15 21:22:26","0 Byte"
"C:\Users\R.J. Bull\Junk\","LPTDOS","2009-09-15 21:22:26","0 Byte"
"C:\Users\R.J. Bull\Junk\","Old_Junk","2009-09-15 21:22:56","0 Byte"
"C:\Users\R.J. Bull\Junk\","T2100-JUNK","2009-09-15 21:23:05","0 Byte"
"C:\Users\R.J. Bull\Junk\","Temp_images","2013-04-17 21:35:44","0 Byte"
"C:\Users\R.J. Bull\Junk\","Temp_screenshots","2013-04-17 21:35:06","0 Byte"
"C:\Users\R.J. Bull\Junk\","zip221","2009-09-15 21:23:05","0 Byte"
"C:\Users\R.J. Bull\Junk\","ZZ_T2100","2009-09-15 21:37:25","0 Byte"

Total number of folders = 8
Sum of file sizes = 0 Byte

IainB

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 6,141
  • Slartibartfarst
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #14 on: August 28, 2013, 06:26:13 PM »
Using xplorer², I just tried this now:
  • 1. Open xplorer¬≤.
  • 2. Select desired Root Directory in a Pane.
  • 3. Press: Ctrl+F (for FIND).
  • 4. Ensure "Named" = *.* (it usually is by default).
  • 5. Untick "files" (so it's folders only, otherwise files and folders are selected by default).
  • 6. Untick "search subfolders" (we're only going 1 level deep).
  • 7. Click OK and wait for search to complete.
  • 8. When the search results come up, select/deselect those columns for display that you want/don't want. Display shows columns for Folder Name, Folder Size, Creation or Modification Date/Time, Path.
  • 9. Press Ctrl+D (replaces <folder> with folder size).
    NB: at this point you could Ctrl+A (select all) and copy all items (Ctrl+C or Ctrl+P) in the search results (including column names) to Clipboard, and then paste into Excel for immediate use.
  • 10. Saved Search as "DCF dcwul62-01.x2fnd".
    NB: At this point you have a repeatable search/display pattern of the above, to run whenever required at some future point.

To repeat in future is a simple 2-step process:
  • 1. Activate the saved search file.
  • 2. Ctrl+A (select all) and copy all items (Ctrl+C or Ctrl+P) in the search results (including column names) to Clipboard, and then paste into Excel for immediate use.

I haven't tried it, but you could probably automate this further using AutoHotKey or AutoIT.

Hope this is of some use/help.

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #15 on: August 28, 2013, 11:21:31 PM »
@IainB / @rjbull

Thank you both for trying to help me.
It is truly appreciated!

The thing is that I want to have :
- foldernames, sizes, dates, paths
- of subfolders only (not files)
- that are on multiple partitions/drives

so, like

X:\basefolder\subfolder1
                     \subfolder2
                     \subfolder3

Y:\basefolder\subfolder-a
                     \subfolder-b
                     \subfolder-c

Z:\basefolder\subfolder-001
                     \subfolder-001
                     \subfolder-001


=
SnagIt-29082013 060613.pngList all subfolders on multiple drives to text of csv
=

Using Directory Opus resulting into excel sheet like this:

=
SnagIt-29082013 061138.pngList all subfolders on multiple drives to text of csv
=

Regretfully, Directory Opus folderprint, sofar, does not accept multiple folders.

=
SnagIt-29082013 061847.pngList all subfolders on multiple drives to text of csv
=

Thanks
=



IainB

  • Supporting Member
  • Joined in 2008
  • **
  • Posts: 6,141
  • Slartibartfarst
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #16 on: August 29, 2013, 01:59:07 AM »
Sorry, I don't understand.
The worked example using xplorer² that I gave indicates that you set up and save a folder search as described - in your case, one each for:
   X:\basefolder
   Y:\basefolder
   Z:\basefolder

The repetitive task then boils down to:
  • 1. Double-click each of the saved search files (3 of them) and wait for the search to complete and display results.
  • 2. Select All, Copy to Clipboard the selected search results for each (3 copy operations).
  • 3. Paste the search results into spreadsheet (3 paste operations).

You could automate this further.

Would that not provide you with the desired result?

stewcam

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 19
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #17 on: August 29, 2013, 07:37:27 AM »
FileLocator Pro can handle this task. Maybe also the freeware version FileLocator Lite (aka Agent Ransack).

rjbull

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 2,927
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #18 on: August 29, 2013, 05:13:08 PM »
The thing is that I want to have :
- foldernames, sizes, dates, paths
- of subfolders only (not files)
- that are on multiple partitions/drives
I tried putting "directory listing csv" into DuckDuckGo and found quite a lot of relevant postings.  One that might suit you is List Maker (I haven't tried it).  But I think that whatever application you use, you will have to run it multiple times to cover multiple drives.  That's why I'd suggest a command line tool, because then you can put it into a batch file to run it as many times as you want with however many drives you have.

stewcam

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 19
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #19 on: August 30, 2013, 01:12:43 AM »
@ rjbull, FileLocator Pro can in fact handle multiple drives in a single pass
« Last Edit: August 30, 2013, 05:18:09 AM by stewcam »

krksoft

  • Participant
  • Joined in 2013
  • *
  • default avatar
  • Posts: 3
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #20 on: August 30, 2013, 04:28:38 PM »
Hi, I am the author of Directory Lister Pro and I believe my software can do exactly what you want.
It can list just folder names (by unchecking the "File rows" option on the "Display" page).
It can list all the properties you want (these are selectable on the first page).
You can select as many directories as you want on the tree.
It can save the listing as an CSV file (choose it on the "Output type" page) which can be directly opened in Excel.
In case of any issues I will personally help you get the listing you want.
Various screenshots (including CSV preview) are located on our web site http://www.krksoft.com

/Leszek

stewcam

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 19
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #21 on: August 30, 2013, 09:52:43 PM »
@ krksoft - impressive; is there a discount available to DonationCoders?

krksoft

  • Participant
  • Joined in 2013
  • *
  • default avatar
  • Posts: 3
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #22 on: August 31, 2013, 02:44:15 AM »
why not ;)
http://tinyurl.com/q4bmj8e
if the link does not work, the coupon code is donationcoder

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,668
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #23 on: September 01, 2013, 11:06:49 AM »
Welcome to the DonationCoder site, Leszek, and thank you for the wonderful gesture.   :Thmbsup:

dcwul62

  • Supporting Member
  • Joined in 2013
  • **
  • default avatar
  • Posts: 293
    • View Profile
    • Donate to Member
Re: List all subfolders on multiple drives to text of csv
« Reply #24 on: September 02, 2013, 01:46:38 AM »
@krksoft - hello to you - thanks for your input here.
I've downloaded/installed your program and have trying to figure out to get the results exactly the way I like.

a. name of parent folder, without... further listing of the name of any subfolders
b. total size of that folder (incl the size of subfolders)

In Directory Opus, I select all folders (ctrl-a), click tools/print, paste into Excel.

The listings look like this.

=
OpusFolderPrint-Pasted into Excel-02092013 080641.pngList all subfolders on multiple drives to text of csv
=

Directory List Pro - by default seems to add the subfoldernames, e.g.
J:\TestFolders\TestFolder-number-001\some folder

=
Directory List Pro-adds subfoldernames-by default-02092013 082124.pngList all subfolders on multiple drives to text of csv
=

I have been 'playing' with Directory List Pro just for a very short while, so bear with me that I have not found the solution that may indeed be available.

- I cud untag all subfolders one by one..
- indeed the \subfolder names are not listed
- but the total size is not correct
at least, as far as I can see, but I might be missing an option here or there :-)

=
Directory List Pro-without subfoldernames added-incorrect size-02092013 082127.pngList all subfolders on multiple drives to text of csv
=