#1 2010-07-30 19:31

bairacdn2005
Member
Registered: 2010-07-30
Posts: 4

Replacing number in order to have a series of images in order

I have a series of image files in 1 folder and I want to view them in order in an album

the file names are from 1 to 100 look like this

abc1.jpg
abc2.jpg
...
abc10.jpg
abc11.jpg
...
abc99.jpg
abc100.jpg


however it is displayed as this order when I view the slideshow

abc1.jpg
abc10.jpg
abc11.jpg
...
abc19.jpg
abc100.jpg
abc2.jpg


I have thought of a way to solve this which is use 3 digits to specify the name as


abc001.jpg
abc002.jpg
...
abc010.jpg
abc011.jpg
...
abc099.jpg
abc100.jpg


so I'll only need to change 1-9.jpg to 001-009.jpg and 10-99.jpg to 010-099.jpg

I tried with those expression but couldn't get any change on them. Can anyone help me please sad

Thank in advance

Last edited by bairacdn2005 (2010-07-30 19:33)

Offline

#2 2010-07-30 20:40

Stefan
Moderator
From: Germany, EU
Registered: 2007-10-23
Posts: 1,161

Re: Replacing number in order to have a series of images in order

If your real file names really contain no numbers, only those at the end, then the simplest way would be:

1.) Add all files in ReNamer in the right order 1,2,3...10,11,12...
2.) Rule STRIP [X] Digits
3.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] Prefix
4.) Preview
5.) see if all as you want
6.) Rename

Did that works for you?


Read the  *WIKI* for HELP + MANUAL + Tips&Tricks.
If ReNamer had helped you, please *DONATE* to Denis or buy a PRO license. (Read *Lite vs Pro*)

Offline

#3 2010-07-31 02:21

narayan
Senior Member
Registered: 2009-02-08
Posts: 470

Re: Replacing number in order to have a series of images in order

If the files are not sorting in the order you want, select the "Sort in natural order..." check box
(Options menu, General tab)

Offline

#4 2010-07-31 05:05

bairacdn2005
Member
Registered: 2010-07-30
Posts: 4

Re: Replacing number in order to have a series of images in order

@Stefan My files are already like this

abc1.jpg
abc2.jpg
...
abc10.jpg
abc11.jpg
...
abc99.jpg
abc100.jpg

so I can't just add more index number after. It wouldnt work

@narayan my viewer on ipad doesn't read it the natural way big_smile but thanks anyway

Offline

#5 2010-07-31 09:15

Stefan
Moderator
From: Germany, EU
Registered: 2007-10-23
Posts: 1,161

Re: Replacing number in order to have a series of images in order

bairacdn2005 wrote:

@Stefan My files are already like this

abc1.jpg
abc2.jpg
...
abc10.jpg
abc11.jpg
...
abc99.jpg
abc100.jpg

Stefan wrote:

2.) Rule STRIP [X] Digits

abc.jpg
abc.jpg
...
abc.jpg
abc.jpg
...
abc.jpg
abc.jpg

Stefan wrote:

3.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] Prefix

abc001.jpg
abc002.jpg
...
abc010.jpg
abc011.jpg
...
abc099.jpg
abc100.jpg


The trick is to first remove all digits from the file names and then add an new, fresh numbering with parameters that suit your needs.
Please note that each Rule does NOT rename the files immediately, but calculate an result and provide an Preview only.
Only if all Rules are done and you are satisfied with the Preview at last YOU will click on Rename.
So step 2 will maybe warn about files with same name, but step 3 will correct this.

If you have not provide good example names and your real file names will contain digits at other places too, then will do it with an other solution!
But this all belongs to the quality of how you request your requirements.


Read the  *WIKI* for HELP + MANUAL + Tips&Tricks.
If ReNamer had helped you, please *DONATE* to Denis or buy a PRO license. (Read *Lite vs Pro*)

Offline

#6 2010-07-31 09:36

Stefan
Moderator
From: Germany, EU
Registered: 2007-10-23
Posts: 1,161

Re: Replacing number in order to have a series of images in order

Stefan wrote:

If your real file names really contain no numbers, only those at the end, then the simplest way would be:

1.) Add all files in ReNamer in the right order 1,2,3...10,11,12...
2.) Rule STRIP [X] Digits
3.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] Prefix
4.) Preview
5.) see if all as you want
6.) Rename

Did that works for you?

OK, i do it big_smile

If your real file names really contain other digits than the numbering at the end:

1.) Add all files in ReNamer in the right order 1,2,3...10,11,12...

ab9c1.jpg
ab4c2.jpg
...
a3bc10.jpg
ab4c11.jpg
...
a7bc99.jpg
ab9c100.jpg

2.) Rule RegEx
Express: (.+\D)\d+
Replace: $1

ab9c.jpg
ab4c.jpg
...
a3bc.jpg
ab4c.jpg
...
a7bc.jpg
ab9c.jpg

3.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] SUFFIX

ab9c001.jpg
ab4c002.jpg
...
a3bc003.jpg
ab4c004.jpg
...
a7bc005.jpg
ab9c006.jpg

4.) Preview
5.) see if all as you want
6.) Rename

---

An other possibility way would be to just add an new numbering in front:

ab9c1.jpg
ab4c2.jpg
...
a3bc10.jpg

1.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] PREFIX
001ab9c1.jpg
002ab4c2.jpg
...
003a3bc10.jpg


Read the  *WIKI* for HELP + MANUAL + Tips&Tricks.
If ReNamer had helped you, please *DONATE* to Denis or buy a PRO license. (Read *Lite vs Pro*)

Offline

#7 2010-08-06 13:06

bairacdn2005
Member
Registered: 2010-07-30
Posts: 4

Re: Replacing number in order to have a series of images in order

hey guys
sorry for the late reply I've been busy last week

I think I can do it now, apply both of your methods smile so thank you all

just one more thing, is there a way to exclude 1 file from the renaming process? Cuz I actually have to do batch renaming for like 50 folder and I wanna automatically exclude this file "bia.jpg". It's always listed as first and so renamer would give something like this

bia001.jpg
untitled-002.jpg
untitled-003.jpg

I would like to have it start at the second file in my folder only. So is there a way to do it?
thank you all
have a nice day smile

Offline

#8 2010-08-06 19:29

Stefan
Moderator
From: Germany, EU
Registered: 2007-10-23
Posts: 1,161

Re: Replacing number in order to have a series of images in order

bairacdn2005 wrote:

just one more thing, is there a way to exclude 1 file from the renaming process?
[...] I wanna automatically exclude this file "bia.jpg".

Hi b.,

please see if this could work for you:

1.) Add all files in ReNamer in the right order 1,2,3...10,11,12...
2.) Rule STRIP [X] Digits

3.) Rule SERIALIZE [Start: 0] [Step: 1] [Pad: 3] Suffix
4.) Rule Replace: Replace all "bia000" with "bia" (skip extension)
5.) Preview
6.) see if all as you want
7.) Rename


----------
@Denis, @All
More elegant would be an PascalScript command "Skip all following Rules and continue with next file"
Then we could do:

1.) Add all files in ReNamer in the right order 1,2,3...10,11,12...
2) Rule PascalScript "If (FileName ="bia.jpg") Then SkipAllFollowingRules()"
3.) Rule STRIP [X] Digits
4.) Rule SERIALIZE [Start: 1] [Step: 1] [Pad: 3] Suffix
5.) Preview
6.) see if all as you want
8.) Rename


Maybe nifty too for
Rule PascalScript "If (WideExtractFileExt(FileName) ="EXE") Then SkipAllFollowingRules()"

Or did i miss here something?


Read the  *WIKI* for HELP + MANUAL + Tips&Tricks.
If ReNamer had helped you, please *DONATE* to Denis or buy a PRO license. (Read *Lite vs Pro*)

Offline

#9 2010-08-06 19:38

Stefan
Moderator
From: Germany, EU
Registered: 2007-10-23
Posts: 1,161

Re: Replacing number in order to have a series of images in order

Ah, an other way to exclude "bia.jpg" from renaming  would be:

1.) Add your files
Now select from context menu (Right mouse click into files list):
2.) > "Mark > Invert Marking" to un-mark all files
3.) > "Mark > Mark by Mask" >> bia.jpg
4.) > "Clear > Clear Marked" to remove all bia.jpg from file list
5.) > "Mark > Invert Marking" to mark all of the left over files again

.


Read the  *WIKI* for HELP + MANUAL + Tips&Tricks.
If ReNamer had helped you, please *DONATE* to Denis or buy a PRO license. (Read *Lite vs Pro*)

Offline

#10 2010-08-09 16:29

bairacdn2005
Member
Registered: 2010-07-30
Posts: 4

Re: Replacing number in order to have a series of images in order

How easy is that big_smile stupid me!
thank for the help Stefan. I really appreaciate it
Have a nice day you all!!

Offline

Board footer

Powered by FluxBB