Quick way to separate files from folders?
so I have this folder that has 587 folders in it. Each one contains one file. I can only view the file if I first open the folder. I would like to take all those files and put them into one folder without doing it one by one 587 times. Is there a clever way of doing this on windows 7?
- ∅Lv 72 months ago
in command prompt.
navigate to the directory containing the folders, and type:
forfiles /s /m *.FILETYPE /c "cmd /c move @file .."
where FILETYPE is the extension of the files, like jpg.
- Laurence ILv 72 months ago
yes provided a few simple rules exist, like so long as there isnt any other files/folders within the the area concerned. create a folder for where to put the copies. then write a batch file with a for loop in it. and FOR each FOLDER simply COPY <using foldername from the FOR>\<Filename using wildcard eg ??????.XXX or *.XXX for the filename> to the destinaton folder. you may need to get tricky if all the files have the same name. save the bat file then execute it from the command line preferably already starting at the correct folder.Source(s): https://docs.microsoft.com/en-us/windows-server/ad... https://www.windows-commandline.com/windows-for-lo...
- FrancisLv 72 months ago
If those files are ending with the same prefix do a search of the overall folder with *. and then the extension type - the search will list all files of that type in the folders which you can then copy and paste to a single folder
- PeteXXX2261Lv 42 months ago
Go to the top folder all the files/sub folders are in. In the search box, top right, type *.* . This will search for all files & folders.
Once the search has finished select all the files (all the folders should be in one block), and the cut them, Ctrl+X.
Navigate to the folder you want to hold all the files then paste, Ctrl+V.
Go back to the original folder and do another search for *.* to check you didn't miss any files, then you can delete the original folder(s).
- How do you think about the answers? You can sign in to vote the answer.
- Anonymous2 months ago
Assuming all the files have the same suffix (like .txt or .jpeg)