Favorite tools - rename by cmd

Discussion and questions - donor version.
Post Reply
Message
Author
vorkosigan
Posts: 2
Joined: 19.12.2016, 19:24

Favorite tools - rename by cmd

#1 Post by vorkosigan » 01.01.2017, 21:29

Hello

What do I make wrong?
I want to rename selected files by adding prefix [x].
When I select one file everything is ok but when multiple files are selected option Separate for each selected item doesn't work or ..:oops: .

FreeCommander XE 2016 Build 734 64-bit donor
Image

vorkosigan

joby_toss
Posts: 1346
Joined: 22.07.2009, 19:19
Location: Romania
Contact:

Re: Favorite tools - rename by cmd

#2 Post by joby_toss » 02.01.2017, 07:49

If I understand correctly, you're trying to create a toolbar button for multi-rename? Why? There already is one.
Image
Image

You can create a renaming Profile so your task could be accomplished easier.
Image
Image

P.S. it works on single items, also; you can use the option Open first profile on start (in Multi rename dialog) so it's even quicker.

afh
Posts: 101
Joined: 30.06.2014, 18:50
Location: Romania

Re: Favorite tools - rename by cmd

#3 Post by afh » 02.01.2017, 08:54

Indeed, %ActivSelName% seems to behave strangely...
You can use "/k echo" in your parameter to see how your command is translated by FreeCommander.

Anyway, this worked for me [with "separate for each selected item" checked, and "enclose each selected item with "" not checked]:

Code: Select all

/c for %i in (%ActivSel%) do (rename %ActivSel% "[x]%~ni%~xi")

vorkosigan
Posts: 2
Joined: 19.12.2016, 19:24

Re: Favorite tools - rename by cmd

#4 Post by vorkosigan » 02.01.2017, 16:06

afh, your code works exactly like I want it to.
THX.

joby_toss - i use this to mark files which were fulfilled, so i want it on simple short-cut :)

Post Reply

Who is online

Users browsing this forum: No registered users and 41 guests