Applying command button to files only, ignore folders. D11

I have a command button that essentially does a regex rename on the selected items.

But I only want the command to apply to files, not folders. And the structure of the locations I'm using the command at make it possible/likely to accidentally include a folder in the selection.

Is there a way to exclude folders from the command, or deselect folders before applying it?

Thank you.

There are a few ways to do it, but adding a line with @filesonly to the command is probably the easiest in this case.

As simple as that :slight_smile:

Thanks Leo, works perfectly!