DonationCoder.com Forum
DonationCoder.com Software => Coding Snacks => Post New Requests Here => Topic started by: midez on November 19, 2018, 01:54 AM
-
Let's say i have a folder with 3500 files. I want them in to folders with ie 400 files in each. Instead of creating a folder, marking 400 files and placing them in that folder, creating a new folder, marking 400 new and place... Yeah, you understand, i would love a software where i enter how many files i want in each folder, i choose were the files are and press go and it's done. It would be great if it was possible to have the folders numbered and choose start number.
-
Hello and welcome to DC!
I could do such i guess, i would need to know:
- Do you need a filemask? ( like *.* )
- Will this operation only be used on a local machine with local drives?
- Must files be sorted in any way? (it would copy by creationtime)
- Do you need a GUI with buttons for all or prefer a CLI like "splitfiles.exe 500 c:\source\ c:\destination\" ?
- Do i need to concern about UniCode Filenames (filenames with non-Latin characters like japanese or greece and similar)
- From point of my logic, no subfolder support should be included, is that correct with your request too?
-
Great!
- Do you need a filemask? ( like *.* )
--- Hmm, i guess no. I want it to take all files in the specific folder.
- Will this operation only be used on a local machine with local drives?
--- Only local.
- Must files be sorted in any way? (it would copy by creationtime)
--- No. I want the files moved to the folders, not copied.
- Do you need a GUI with buttons for all or prefer a CLI like "splitfiles.exe 500 c:\source\ c:\destination\" ?
--- It would be good with a GUI. I can make a mockup if you want?
- Do i need to concern about UniCode Filenames (filenames with non-Latin characters like japanese or greece and similar)
--- Yes please.
- From point of my logic, no subfolder support should be included, is that correct with your request too?
--- No subfolders
-
Sneak peak on how i thought it could be, if you dislike just tell, i keep coding proper functions now.
[ You are not allowed to view attachments ]
-
It looks good! In "Choose destinations prefix" i can enter any number i want it to start on?
-
No, there you should enter destinations folder initial name, like "Anything", my app would add "Anything" to Destinations Rootpath with proper number added like "Anything_1" or "Anything_0001" i will fill it up with zeros to match created folder count.
If you need to tweak starting number, i can add that too.
-
So it will create a folder called ie Anything_1 and under that it will place subfolders (numberd) for each 500-files folder? It would be great if i can enter a start number.
-
[ You are not allowed to view attachments ]
I hope this image make it now more clear, any questions left?
Source would be something like c:\download\
Destination Root something like c:\splitted\
Filelimiter = 666
Initial Name something like "Its Splitted now"
Initial counter = 1234
If press "Begin" it would collect all files inside Source.
Then it would create first folder as "c:\splitted\Its Splitted now_1234" and move 666 files into.
Repeat by increase foldernumber until no more files left.
-
This looks great! Just one question; do i have to enter anything in "Initial Name" or could i just have it numbered?
-
There is no need to enter initial foldername. Destination Root will be used and "1" "2" "3" etc will be created in there, depends on your initital count number, by default its "1" and would add zeros infront, if +9 folders = number be like "01" or if +99 folders = "001" etc..
-
Now i look forward to testing it! :D :up:
-
First public release can be downloaded here. (https://usercontent.irccloud-cdn.com/file/VsSOrPmT/SplitFiles.7z)
[ You are not allowed to view attachments ]
Manual:
Download archive and extract with 7zip or compatible the .exe file.
Run SplitFiles.exe and you see above GUI.
Select source folder by clicking on [..]
Select destination folder by clicking on [..]
Tune options to your needs.
As soon as you click on "Begin" it will instant work without any more messages, just doing its job.
In StatusBar i tried to tell you status all the time.
Attention:
This program do not check destination for existence, neither folder nor files !
So always take care what you doing !!!
I hope this tool work for you as good as i could tested on my own.
Regards,
KodeZwerg.
-
minor Update. (https://usercontent.irccloud-cdn.com/file/IxZLe6nd/SplitFiles.7z)
Whats new?
- Added a mainmenu with gigantic two options :-)
- Now you can choose working mode, Move (default) or Copy
- Since it cost no time, files are sorted now
Whats next?
- you tell me.
Enjoy,
KodeZwerg.
-
It works great! Just a couple of minor things;
When it works the statusbar is not showing all the info. It cuts of parts of the text.
[ You are not allowed to view attachments ]
Even thou i'm entering 0001 it still gives me 01 and counting.
[ You are not allowed to view attachments ]
[ You are not allowed to view attachments ]
Other then that i'm more than satisfied!
Thanks!
-
Strange thing that the StatusBar text dont fit into... i will investigate that.
When you start application, does in that case the text fit or same thing?
To folder numbering, my application works this way:
- it collect all files
- calculate how many folders are needed to be created
- starting with whatever decimal number you enter ( decimal 0000000001 would always be just a decimal 1 )
- it automatic fill up foldernumber with zeros to match final created folder, heres how it do if initial number is 1 =
- if my application need to create 9 folders, no zero be added
- if my application need to create 10-99 folders, one zero be added to 1-9
- if my application need to create 100-999 folders, two zeros be added
and so on....
- I might add a feature to let you define how many Characters a final foldername should have and fill rest up with zero
It works great!
...
Other then that i'm more than satisfied!
Thanks!
-midez
Nice to hear and you are welcome :-)
I try fix StatusBar and add your requested feature....
-
Yeah it fits when it starts.
Skip my counting issue, i'm fully satisfied as it is as well.
-
Yeah it fits when it starts.
Skip my counting issue, i'm fully satisfied as it is as well.
-midez
It looks like this is a behavior of windows to fully overheated applications ^_^
In this build i replaced StatusBar with Static Text (https://usercontent.irccloud-cdn.com/file/sph9bOE4/SplitFiles.7z)
Rest of Application is like prior release, good that the zero issue aint a real problem :)
Have fun using it,
KodeZwerg.
BTW i forgot to tell you, since its my way to interprete things....
in folder select box (when you hit on [..] for paths)
if you need to create subfolders
just switch there where you need one
in first line you see the path up to there
just add "\A Sub Folder" to it and press Return
it will ask you to create it for you.
-
Thanks a lot for this! This helps me a great deal!
-
Thanks a lot for this! This helps me a great deal!
-midez
You are welcome, was fun doing it.
@Operators, feel free to move topic to finished.
Have a nice Day!