Batch Rename with removal of characters

Ask for help and post your question on how to use XnView Classic.

Moderators: helmut, XnTriq, xnview

Post Reply
Haral
Posts: 2
Joined: Sat May 07, 2011 7:15 am

Batch Rename with removal of characters

Post by Haral »

I have a lot of files with the name in the format "YYYY-MM-DD_HH-MM-SS – Text string – Original File name.jpg"
YYYY-MM-DD_HH-MM-SS have been added by running Batch rename and it is the time the pictures were taken.
After adding the date I found the time on my camera to be wrong – I then ran the “Tools | Change Timestamp”. So far so good.

But now I want to change the time in the file names to reflect the time the pictures really were taken.
In the Batch Rename dialog box there is a field for Start / Step. I can not find any info about how to use this. Nice if somebody can tell me hwo it can be used.

I want to get rid of the first part of the file name. My hope was that I could use the “Replace” function, but how can I tell it to remove the first 19 characters from the file name and then insert “Date Taken” in the front of the file name?
I missing a renaming tool where I can tell Xnview to replace [start 1 to end 19] with “Date taken [YYYY-MM-DD_HH-MM-SS]".

Is this possible or do I have to find another solution?

Thanks a lot for a nice program.

Harald
User avatar
helmut
Posts: 8704
Joined: Sun Oct 12, 2003 6:47 pm
Location: Frankfurt, Germany

Re: Batch Rename

Post by helmut »

The function you need is not replace, but "use chars from position [x] to position [y]". XnView does not offer such a "sub string" function.

I guess you will not get around downloading a more powerful renaming tool, and...
a.) ...either do the full rename with the new rename tool.
b.) ...do one part of the renaming with the new rename tool and do the image related rename part with XnView.

Perhaps the topic 'Recommended File-Rename-Tools?' might be of some help. For example, the rename tool 'Joe' supports substrings.
Haral
Posts: 2
Joined: Sat May 07, 2011 7:15 am

Re: Batch Rename with removal of characters

Post by Haral »

Hi

Thanks for let me know. I actual solved my problem by scripting in Excel and renamed the files using the script. But it would be nice if it was possible to exclude part of the file name when using the rename function in XnView.

Harald
User avatar
helmut
Posts: 8704
Joined: Sun Oct 12, 2003 6:47 pm
Location: Frankfurt, Germany

Re: Batch Rename with removal of characters

Post by helmut »

Haral wrote:Thanks for let me know. I actual solved my problem by scripting in Excel and renamed the files using the script.
Good that you could resolve your problem, Harald. Always good to know a scripting language. :-)
Haral wrote: But it would be nice if it was possible to exclude part of the file name when using the rename function in XnView.
Yes, using only parts of the original filename is really missing in XnView batch rename.

- Helmut
Post Reply