Paste in Rename

Have a suggestion for "Everything"? Please post it here.
Post Reply
etc
Posts: 49
Joined: Tue Jun 24, 2014 7:17 pm

Paste in Rename

Post by etc »

In Rename window:
Paste a file list (all the files exist) into "Old Filenames" box. (By pasting I can use a sorted list, etc.)
Paste another list (the amount and all the names are valid) into "New Filenames" box.
But the OK button is grayed.

How to make such uses work?
therube
Posts: 4580
Joined: Thu Sep 03, 2009 6:48 pm

Re: Paste in Rename

Post by therube »

I had never thought about pasting into Old.
(It is a bit awkward.)

Don't see where pasting into New makes sense?
Unless you're wanting to do a 1 to 1 (old to new) rename.


Bulk Rename Utility has a "Named Pairs" function.
And that too is a bit awkward.
But if you have 2 sets of data & are looking for a 1 to 1 rename, it might work out.

https://www.bulkrenameutility.co.uk/

Renaming From A Text File

With Bulk Rename Utility it is possible to rename files according to a text file. The text file should contain a list of "old name" and "new name" pairs, separated by a pipe symbol ( | ) or a comma ( , )

To use this facility, create a text file in for the correct format, for example:

Track001.mp3|Headlong.mp3
Track002.mp3|Rushes.mp3
TRACK003.mp3|AnywhereIs.mp3

or use comma separated (CSV)

Track001.mp3,Headlong.mp3
Track002.mp3,Rushes.mp3
TRACK003.mp3,AnywhereIs.mp3

One entry per line.

Next, click the Import Rename-Pairs on the Actions menu and select your file. If the file is valid, then select files to rename and you will see the "new name" column reflecting the contents of the text file.

When comparing the current filename with the text file, the application ignores the case of the filename, e.g. it will match Track001.mp3 and TRACK001.mp3. This makes it easy to rename the files.

Bulk Rename Utility will read ANSI and Unicode (UTF-16) text files.


Note: You can view all the imported rename-pairs by selecting 'View Imported Rename-Pairs' from the Bulk Rename Utility menu.
(I believe all files need to be in the same directory. I.e., you cannot provide a path+file name to the files, only the name.)
NotNull
Posts: 5167
Joined: Wed May 24, 2017 9:22 pm

Re: Paste in Rename

Post by NotNull »

Not sure if this was a suggestion or a support question. If it is a support question:
The new New filenames pane is "passive"; you can't use it as as an input field.

therube wrote: Sat Jun 27, 2020 5:19 pm I believe all files need to be in the same directory. I.e., you cannot provide a path+file name to the files, only the name.
PowerShell comes to mind for these cases. Should be doable in a couple of lines of code. Let me know when interested.
void
Developer
Posts: 15096
Joined: Fri Oct 16, 2009 11:31 pm

Re: Paste in Rename

Post by void »

Currently...

The old filenames can be edited to help match the old format.
When renamed the original filenames that the renamer initialized with are used.
You cannot add files to the renamer, unless you drag drop files.

I'll look into pasting file names. You would have to specify the full path and filename when doing so..
Thanks for the suggestion.
NotNull
Posts: 5167
Joined: Wed May 24, 2017 9:22 pm

Re: Paste in Rename

Post by NotNull »

NotNull wrote: Sat Jun 27, 2020 11:18 pm PowerShell comes to mind for these cases. Should be doable in a couple of lines of code.

Code: Select all

Param(
  [Parameter(Mandatory=$True,Position=1)]
   [string]$old_names,
	
   [Parameter(Mandatory=$True,Position=2)]
   [string]$new_names,
   
   [switch]$execute = $false
)


$old = gc $old_names
$new = gc $new_names

for ($i=0;$i -lt $old.Count; $i++) {
	rename-item -LiteralPath $old[$i] $new[$i] -whatif:(!$execute) 
}
Post Reply