Batch rename

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Batch rename

Post by myrnalarson »

When using Batch Rename, the increment can be a number or a date. Is it possible to use a letter, e.g. test-a, test-b, test-c, etc?

j_c_hallgren
XY Blog Master
Posts: 5826
Joined: 02 Jan 2006 19:34
Location: So. Chatham MA/Clearwater FL
Contact:

Re: Batch rename

Post by j_c_hallgren »

Since you're new here, you may not realize that we don't need threads to always be in the 'proper' sub-forum so I'd suggest you delete the similar "wish" thread and just revise your request here...Don will still see it and it keeps the forum cleaner...thanks!
Still spending WAY TOO much time here! But it's such a pleasure helping XY be a treasure!
(XP on laptop with touchpad and thus NO mouse!) Using latest beta vers when possible.

myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Re: Batch rename

Post by myrnalarson »

The problem is that I thought I had posted under this topic, but I couldn't find it. I asked for all messages posted by me and it didn't show up.

So I posted it again, this time in the Wish List. I'll delete that one.

Thanks for the tip!

j_c_hallgren
XY Blog Master
Posts: 5826
Joined: 02 Jan 2006 19:34
Location: So. Chatham MA/Clearwater FL
Contact:

Re: Batch rename

Post by j_c_hallgren »

There's a lot to know about XY and lucklily we have a wide variety of forum regulars here who each have their area of expertise...I've tended to try and help the first-time or new users since I'm not a user of some features of XY since my needs are limited (no scripting or networks)...all we ask is that you try and search prior threads to avoid duplicates...sometimes the keywords to search for can be hard to determine for new users so I can help with that on occasion.
Still spending WAY TOO much time here! But it's such a pleasure helping XY be a treasure!
(XP on laptop with touchpad and thus NO mouse!) Using latest beta vers when possible.

admin
Site Admin
Posts: 66360
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Batch rename

Post by admin »

myrnalarson wrote:When using Batch Rename, the increment can be a number or a date. Is it possible to use a letter, e.g. test-a, test-b, test-c, etc?
Yes. Open Tools | Configuration | Templates | Incremental Suffix and enter "-a" as suffix.

myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Re: Batch rename

Post by myrnalarson »

I'm still having problems with this.

Let's say I have this series of files: 00 01.jpg, 00 02.jpg, 00 03.jpg

The incremental suffix is a space followed by the letter a.

In the batch rename box I type 00. The preview shows 00.jpg, 00 b.jpg, and 00 c.jpg. The first file doesn't get the letter a, as I want.

Or, let's say I have these files: 00 a.jpg, 00 b.jpg, 00 c.jpg. I want to change the letter suffix to a 2-digit number, beginning with 1. (i.e. a = 01, b = 02, c = 03, etc)

In Configuration, I set the suffice to a space followed by 01, (meaning I want to assign 01 to the 1st file, 02 to the 2nd, etc). Then I try to rename the files. I type just 00 in the rename dialog. The result is files named 00.jpg, 00 11.jpg and 00 21.jpg.

So it seems to interpret the 0 as the trigger for sequential numbers, and the 2nd digit (1), is not incremented but tacked on the end.

Perhaps I'll have to write a script for this. I've been programming in DOS and Visual Basic for 40 years now, so I think I'll be able to tackle it.

admin
Site Admin
Posts: 66360
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Batch rename

Post by admin »

myrnalarson wrote:I'm still having problems with this.

Let's say I have this series of files: 00 01.jpg, 00 02.jpg, 00 03.jpg

The incremental suffix is a space followed by the letter a.

In the batch rename box I type 00. The preview shows 00.jpg, 00 b.jpg, and 00 c.jpg. The first file doesn't get the letter a, as I want.

Or, let's say I have these files: 00 a.jpg, 00 b.jpg, 00 c.jpg. I want to change the letter suffix to a 2-digit number, beginning with 1. (i.e. a = 01, b = 02, c = 03, etc)

In Configuration, I set the suffice to a space followed by 01, (meaning I want to assign 01 to the 1st file, 02 to the 2nd, etc). Then I try to rename the files. I type just 00 in the rename dialog. The result is files named 00.jpg, 00 11.jpg and 00 21.jpg.

So it seems to interpret the 0 as the trigger for sequential numbers, and the 2nd digit (1), is not incremented but tacked on the end.

Perhaps I'll have to write a script for this. I've been programming in DOS and Visual Basic for 40 years now, so I think I'll be able to tackle it.
It works as advertised: inn the definition "0" stands for a numerical increment starting with "1", "a" stands for an alphabetical increment starting with "b".

myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Re: Batch rename

Post by myrnalarson »

You show as one of the examples _00, i.e. with 2 zeroes. I (obviously incorrectly) assumed that if I specified 01, it would mean "start with 1 instead of 0" (i.e. similar to the <#01> syntax).

It looks to me as though I can only get what I want with numbers if I use the <#01> syntax, and there's no way to specify (with similar syntax) that I want the 1st file to have the letter a added, the 2nd the letter b, etc.

Is that correct?

admin
Site Admin
Posts: 66360
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Batch rename

Post by admin »

Correct.

admin
Site Admin
Posts: 66360
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Batch rename

Post by admin »

myrnalarson wrote:You show as one of the examples _00, i.e. with 2 zeroes. I (obviously incorrectly) assumed that if I specified 01, it would mean "start with 1 instead of 0" (i.e. similar to the <#01> syntax).
Well, I thought about it and it makes sense. I could quite easily change it to work as you wish. Then increment template and <#01> syntax would work identical. The latter will then also support letters <#aa>.

There's a little problem with upgrading: To keep the current behavior as it is for upgraders I could attempt to autoconvert "-00" to "-01", "_000" to "_001", "-aa" to "-ab" etc. but it will be hard to cover all possible patterns. But I think only a very small minority of users will have other patterns here anyway.

myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Re: Batch rename

Post by myrnalarson »

i (obviously) would be in favor of the change, but don't go to all that work just for one user.

admin
Site Admin
Posts: 66360
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Batch rename

Post by admin »

myrnalarson wrote:i (obviously) would be in favor of the change, but don't go to all that work just for one user.
I like it too, that makes two of us. :)

myrnalarson
Posts: 68
Joined: 29 Apr 2011 16:46

Re: Batch rename

Post by myrnalarson »

With 2 votes in favor, there's only one that matters, and that's yours :D

PeterH
Posts: 2828
Joined: 21 Nov 2005 20:39
Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%

Re: Batch rename

Post by PeterH »

I think Don is fair, he doesn't count his own vote. 8)
But if he likes yours, he counts it twice. :shock:
(At least...) :wink:

But don't get me wrong: thats OK :D

Post Reply