Create folders from an Excel sheet
Let’s say that you’re working on a project and you have an Excel sheet that contains 100 names. For part of your project, you need to create a folder for each of the names. If you don’t want to create a new folder and name it 100 times, I have a very simple solution for you.
In this example, we’re starting out with this:

Step 1. Highlight the “A” column and select “Insert”.
Step 2. In the new “A” column type the letters “md” into the first row.

Step 3. Save the Excel sheet as a CSV (Comma delimited) file.
Step 4. Right-click on the new .csv file and choose to open in Notepad.
It should look like this:
md,folder1
md,folder2
md,folder3
and so on…
Step 5. Click on “Edit” and then select “Replace…”.
Step 6. Replace every comma with a space.
Step 7. Save the file as “filename.bat” and change the file type to “All Files”.
(This makes the file executable.)
Step 8. Double-click on the new .bat file.
Note: The new folders will be created in the same directory that the .bat file is in. So, if you don’t want 100 folders on your desktop, don’t run the .bat file from the desktop.
Comments
8 Responses to “Create folders from an Excel sheet”
Leave a Reply










I just used this technique again today.
This is some batty good stuff!! – I’ll be sure to fly to this site on a regular basis and navigate through every single blue link often…
Some of my names have spaces in the title for example “John Doe.”
How do I create a folder that reads “John Doe.”
Right now I am only getting a folder named “John”
If you put the folder name in quotes in your batch file, it will work.
md “John Doe”
md “Sally Jones”
Worked perfectly – thank you so much.
good
any idea about sub folder
OMG whoever wrote this I love you so much!
I wish I found this 2 hours ago – what a totally simple solution …. thank you so much!