Renaming files to folder name and numering them

I have a need of create a button to do this simple task; rename all the files in a folder with the folder name and numering them, something like this: FolderName - 01.jpg
cna any of my friends here help me to create the code, thanks. :slight_smile:

Rename FILEINFO NUMBER 01 BY 1 PATTERN "^.(..)$" TO "{parent1} - [#]\1" REGEXP

Nice, thank you very much.

I already have a button using this code:

Rename FILEINFO PATTERN "*" TO "{parent} - [#2].{ext}" NUMBER 

Are there any benefits in using your method? (I'm still slowly learning RegExp...very slowly).

Your way is simpler and a better choice. I've been using RE's for so long, they are my natural choice.

Fair enough. It's always nice to see alternative methods anyway... keep them coming.