Export Folder Structure or Folder List to Excel, CSV or XML – Folder Size 4.7.0.0

Export Folder Tree and List
22

Dec

Folder Size is an advanced free folder and file size analysis tool. It can export all file and folder information to Excel, XML, or CSV. It can also export folder structure to PDF or print to the printer. These are just a few of the countless features of Folder Size. In addition, it can list the largest folders and files, analyze the disk space using neat pie and bar charts, list the largest and oldest files in a folder and all its subfolders. That is to say, it is the best tool for locating missing disk space – it will display the size distribution of all your files and folders.

Download Folder Size now and save valuable disk space by removing large unused files and folders. Please take a look at this article If you are interested in printing folders.  There is also a detailed article on how to print files or folders.

Export Folder

Export Folder

Export Folders to Excel, XML, CSV

There are many export options and file formats in Folder Size. First, you should know what you want to export.

Export Files or Folder

  • File->Export Chart Image – will export the chart as a graphic file
  • File->Export As… – will export all the information – this includes all files and folders
  • File->Export Details View – will export only the file and folders listed in the large details view at the right side of the application

Export Formats – Excel, CSV, ot XML

The second two options above will let you choose the file format. For example, if you want to export the data to EXCEL you should choose a CSV file extension. The CSV file format provides a table-view structure of the folders and files. As a result, you can view the CSV files in Excel. Excel supports CSV files natively.

If you want to export the tree structure of folders and files use the XML file format. You can easily display XML files in a web browser. You can also use them to import the data from other applications.

Folder and File Export Options

Folder and File Export Options

Folder and File Export Options

The above options determine the export settings for the full “Export As…” feature. An explanation of each item follows below.

Include drive size information for scanned locations (if available)

The option name is clear enough – it includes information for the used, free and total space of the drive which contains the scanned files. The “if available” part is there because certain types of network share do not contain such information.

Export File Details

Determines if the file information will be included in the exported files. To clarify, untick the option to export folder list/tree only. Large scans may contain many items and the exported files can grow large. Therefore, if you do not need the file information it is better to un-tick the option.

Export Owner Information

The owner information is usually not needed and is not exported by default. Another reason to exclude this information by default is that the Windows API for obtaining such information is quite slow. Therefore it may slow down the entire export if it contains a large number of files or folders.

Maximum Export Depth

The option is set to 0 (ZERO) by default which translates to UNLIMITED – export all levels. In short, it limits the depth of the exported folders and starts from the top-level inclusive. The number determines how deep the tool should export.

Export Folder List or Export Folder Structure From Command Line

Folder Size provides multiple options in order to automate the folder scan and export process. It provides all the export options also from the command line.

Here is a detailed export example:

FolderSize -scan “F:\mp3” -exp “d:\mp3_{DATE} {TIME}.xml;d:\mp3_{DATE} {TIME}.fsp;d:\mp3_{DATE} {TIME}.csv” -s -exp-depth 4 -exp-files-off -exp-drive-info-on

-scan <path> – specifies a path that will be scanned. You can specify multiple paths by separating them with a semicolon. You should enclose in quotes all paths that contain spaces. E.g.: -scan c:\mp3;“c:\path with space”

-exp <semicolon delimited list of export formats> – Export command line parameter. Depending on the file extension will export the corresponding file type. You can export multiple formats at once by separating the paths with semicolons. Use the variables {DATE} and {TIME}  to include the current date and time in the file names.

Export Options and Flags

Below export options have on and off states. If you omit an option the value from the application GUI settings is used for backward compatibility. If you do not want that, you should explicitly specify the desired state of the option. Please note that the settings below will be set in the application. If you use the “-s” (silent) option they will not be stored. If you omit the “-s” option, closing the application window will store the command line settings in the application’s settings.

-exp-drive-info-on
-exp-drive-info-off – Include/exclude information for the drive size, free and used space in the exported file if available. Such information may not be available for some network shares.

-exp-files-on
-exp-files-off – Include/exclude information for the files in the exported file.

-exp-owner-on
-exp-owner-off – Include/exclude owner information for the files and folders. This option is disabled by default. The Windows API for obtaining OWNER information is very slow and may cause poor performance for large folder listings. Therefore, if you do not need the owner information we recommend you to keep the option disabled.

-exp-depth XX – Determines how many levels deep to export from the top folder inclusive. XX is a round value equal to 0 (zero) or higher. The default value is 0 (zero). It means that the tool will export ALL the data – unlimited.

-s – stands for SILENT. Use the option to hide the GUI during the scan. The application will exit after it processes the command line actions. However, you can omit the option to display the GUI. As a result, it will stay on screen after it processes all the command line actions.

Folder Tree XML Export File format sample:

<fo tc=”4/9/2011 12:18:02 AM” ta=”7/1/2011 8:34:40 AM” tm=”7/1/2011 8:34:40 AM” at=”8208″ fic=”1″ foc=”0″ s=”1721″ ow=”WIN-LQEN7914IFU\Chris” >
<n>
<![CDATA[Toolbar]]>
</n>
<fo tc=”7/1/2011 8:34:26 AM” ta=”7/1/2011 8:34:40 AM” tm=”7/1/2011 8:34:40 AM” at=”8224″ s=”1721″ ow=”WIN-LQEN7914IFU\Chris” >
<n>
<![CDATA[broker_metrics.xml]]>
</n>

We have shortened the attributes and tags of the XML file to reduce file size. As a result the size of the files gets smaller. Bear in mind that those files may contain millions of items and every character counts.

Folder Tree XML Attribute and tag names:

  • fo – Folder/file object
  • tc – Time created
  • ta – Time accessed
  • tm – Time modified
  • at – Attributes – decimal representation of the file/folder attributes. These are all the standard Windows file attributes. Read more: https://docs.microsoft.com/en-us/windows/win32/fileio/file-attribute-constants
  • fic – Files count
  • foc – Folders count
  • s – Size
  • ow – Owner
  • n – Name is stored in a CDATA section in order to support multiple language characters.

Command-line export options are available only in the PRO version of the application.

Folder Size is a great free tool that will list folder sizes and export or print folders and file lists.

Do you miss a feature or have a suggestion? Please comment below – we will be glad to hear your recommendations.

The article relates to:
Easy guide to export folder structure.
How do I export a list of folders?
Can I extract files from multiple folders?
How do I print a folder tree structure?
I want to create a directory structure in Excel?
Guide to write a folder structure?
Help to export a folder structure?
Info to get a list of folders and subfolders?
How do I export a list of files from a folder into Excel?
Can I extract files from multiple folders?

1 thought on “Export Folder Structure or Folder List to Excel, CSV or XML – Folder Size 4.7.0.0

  1. Pingback: Find Long Paths & Long File Names

Leave a Reply

Your email address will not be published. Required fields are marked *