Hi,
I am dealing with a large photo folder and wanted to split this folder into sub-folders each containing no more than 2000 files. How do I use TC to automatically do this?
I searched the internet and checked this forum but could not find relevant hits.
Any ideas?
Thanks
How to automatically split a large folder into sub folders containing 2000 files?
Moderators: Hacker, petermad, Stefan2, white
-
- Junior Member
- Posts: 13
- Joined: 2019-05-15, 12:23 UTC
Re: How to automatically split a large folder into sub folders containing 2000 files?
With TC as you do not have math operator with counter nor additional variable it could be quite hard to find a solution.
The best would be to use Total Commander to sort and select all the files you want to move into sub folder and then use a scripting language to :
count files 1 by 1,
create folder (modulo 2000) and increase folder name,
move file to current folder
This can be done with powershell, dos script with TCBL, ...
The best would be to use Total Commander to sort and select all the files you want to move into sub folder and then use a scripting language to :
count files 1 by 1,
create folder (modulo 2000) and increase folder name,
move file to current folder
This can be done with powershell, dos script with TCBL, ...
-
- Junior Member
- Posts: 13
- Joined: 2019-05-15, 12:23 UTC
Re: How to automatically split a large folder into sub folders containing 2000 files?
Thank you nsp for your reply.
Re: How to automatically split a large folder into sub folders containing 2000 files?
The forum contains already many solutions, a few are...
Kopieren einer vorgegebenen Anzahl von Bildern in neue Ordner
https://www.ghisler.ch/board/viewtopic.php?p=383314#p383314
Plugin "Mover" and VBScripts
and Ghislers' Mehrfach-Umbenenntool-Trick:
5. Geben Sie folgenden Umbenenntext an anstelle von [N]:
Ordner[C+1/406:2]\[N]
How to select the first 1000 or 900 files?
Select-Amount-Of-Files AutoHotkey
viewtopic.php?p=307215#p307215
AutoHotkey: Select first n files, Select every n'th file
viewtopic.php?p=298324#p298324
With Romans' simple AutoHotkey-Script:
WinActivate, ahk_class TTOTAL_CMD
WinWaitActive, ahk_class TTOTAL_CMD
; cm_GoToFirstFile
PostMessage, 1075, 2050
SendInput, {Insert 2000}
Not sure if one or another works for you or are a starting point....
Kopieren einer vorgegebenen Anzahl von Bildern in neue Ordner
https://www.ghisler.ch/board/viewtopic.php?p=383314#p383314
Plugin "Mover" and VBScripts
and Ghislers' Mehrfach-Umbenenntool-Trick:
5. Geben Sie folgenden Umbenenntext an anstelle von [N]:
Ordner[C+1/406:2]\[N]
How to select the first 1000 or 900 files?
Select-Amount-Of-Files AutoHotkey
viewtopic.php?p=307215#p307215
AutoHotkey: Select first n files, Select every n'th file
viewtopic.php?p=298324#p298324
With Romans' simple AutoHotkey-Script:
WinActivate, ahk_class TTOTAL_CMD
WinWaitActive, ahk_class TTOTAL_CMD
; cm_GoToFirstFile
PostMessage, 1075, 2050
SendInput, {Insert 2000}
Not sure if one or another works for you or are a starting point....
Re: How to automatically split a large folder into sub folders containing 2000 files?
1. Sort files with desired order - by name or time or any other.
2. Select all files - CTRL+A
3. Start Multi=Rename Tool with default settings - CTRL+M
4. Prepend filename withso you get in "Rename mask: file name"
5. Press "Start"
If you wish folder names with fixed chars length {with leading zero(s)} change this to e.g. where "5" is number of digits.
This way you get EXACTLY 2000 files in each subfolder (probably except the last one).
2. Select all files - CTRL+A
3. Start Multi=Rename Tool with default settings - CTRL+M
4. Prepend filename with
Code: Select all
[C+1/2000]
Code: Select all
[C+1/2000]\[N]
If you wish folder names with fixed chars length {with leading zero(s)} change this to e.g.
Code: Select all
[C+1/2000:5]\[N]
This way you get EXACTLY 2000 files in each subfolder (probably except the last one).