Page 1 of 1

Can split folder?

Posted: 11 Apr 2008 01:24
by wbnew
I have 5000 files in one folder
I will make 50 subfolder, one folder have 100 files.
XYplorer can do this?
how?
Thank you

Re: Can split folder?

Posted: 11 Apr 2008 08:18
by admin
wbnew wrote:I have 5000 files in one folder
I will make 50 subfolder, one folder have 100 files.
XYplorer can do this?
how?
Thank you
There should be a way in scripting to
- select the top 50 [EDIT: should be 100, of course]
- move them to an autonamed-subfolder

After assigning a keyboard shortcut to it, it would mean 50 keystrokes for the job. Of course, once scripting gets loops it will be one keystroke...

Posted: 11 Apr 2008 14:25
by TheQwerty
This seems to work pretty well, you have to answer a single prompt each time through (the recursive checker) and break out of the loop yourself, but that's not too bad.

Depending on how you want to separate the files you may need to change the second SortBy function.

Code: Select all

"mover"
	Setting(HideFoldersInList, 0);
	//Create new folder (using suffix to avoid collision)
	#231;
	SortBy(Created, d);
	Sel(1,1);
	Set($d, <curitem>);
	Setting(HideFoldersInList, 1);
	SortBy(Name, a);
	Sel(1,100);
	Focus(List);
	MoveTo($d);
	Sub(mover);
Also, you can speed it up significantly by doing the following:
Turning off auto-sizing columns (View -> List View -> Autosize Columns)
Using a simple view (List and Small Icon work well)
Hiding the tree (Window -> Show Navigation Panel)
And making the window you're going to run this in as small as possible.

Posted: 11 Apr 2008 15:52
by admin
TheQwerty wrote:This seems to work pretty well, you have to answer a single prompt each time through (the recursive checker) and break out of the loop yourself, but that's not too bad.

Depending on how you want to separate the files you may need to change the second SortBy function.

Code: Select all

"mover"
	Setting(HideFoldersInList, 0);
	//Create new folder (using suffix to avoid collision)
	#231;
	SortBy(Created, d);
	Sel(1,1);
	Set($d, <curitem>);
	Setting(HideFoldersInList, 1);
	SortBy(Name, a);
	Sel(1,100);
	Focus(List);
	MoveTo($d);
	Sub(mover);
Also, you can speed it up significantly by doing the following:
Turning off auto-sizing columns (View -> List View -> Autosize Columns)
Using a simple view (List and Small Icon work well)
Hiding the tree (Window -> Show Navigation Panel)
And making the window you're going to run this in as small as possible.
Not bad! :D

Posted: 11 Apr 2008 16:17
by TheQwerty
Still some problems with it though:
Updated version:

Code: Select all

"mover"
   Setting(KeepFoldersOnTop, 1);
   Setting(SortFoldersApart, 1);
   Setting(HideFoldersInList, 0);
   //Create new folder (using suffix to avoid collision)
   #231;
   SortBy(Created, d);
   Focus(List);
   Sel(1,1);
   Set($d, <curitem>);
   Setting(HideFoldersInList, 1);
   SortBy(Name, a);
   Sel(1,100);
   Focus(List);
   MoveTo($d);
   Sub(mover); 
And it can cause XY to crash.
If you shrink the window down as much as possible and leave the tree visible, #231, causes it to crash.

So hide the tree!

Posted: 12 Apr 2008 09:33
by admin
TheQwerty wrote:And it can cause XY to crash.
If you shrink the window down as much as possible and leave the tree visible, #231, causes it to crash.
Fixed.