Folder count


#1

Can you write function that can count folders from string (%_path%, %_workingpath%...)?

Examples:

$foldercount(G:\Music\Progressive Trance\Sasha And John Digweed - Communicate\Sasha And John Digweed - Communicate Cd 1)
RETURNS NUMBER 4

$foldercount(G:\Music\Progressive Trance\Avalanche Of Sound Vol.3)
RETURNS NUMBER 3

$foldercount(%_workingpath%)
RETURNS NUMBER 2
%_workingpath% = G:\Music\Progressive Trance\

You can use "" as separator.

~ Thanks, milka.


#2

Maybe $folderlevel or $folderdepth is a more appropriate name for such a function, because $foldercount seems to refer to the number of subdir in a given path...


#3

This should be possible ... I'm not sure, if it'll make it to the next release.

Best regards,
~ Florian


#4

The new function $folderdepth(path) is scheduled to the next release.

Examples:
$folderdepth(C:) => 0
$folderdepth(C:\folder1\folder2) => 2

Best regards,
~ Florian


#5

Thanks man :w00t:


#6

The new function is implemented with the latest Development Build :slight_smile:

Best regards,
~ Florian


#7

Thanks again, I can't wait to try it. :slight_smile: