Batch convert - rename fails

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

Moderators: XnTriq, xnview

Post Reply
mcbrx
Posts: 18
Joined: Mon Nov 06, 2017 1:03 pm

Batch convert - rename fails

Post by mcbrx » Tue Jan 21, 2020 9:58 pm

Hi,

I convert old photos and change the file name, which then, among other things, should contain the camera model ({EXIF:Model}).
But, the batch conversion fails if there are strange EXIF ​​entries (see attached picture).
Can XnViewMP automatically exchange characters that are not allowed in the file system?
As a user, I am unfortunately unable to do this during batch conversion.

Thank you!
Attachments
Screen-EXIF-XnViewMP.jpg
Screen-EXIF-XnViewMP.jpg (15.69 KiB) Viewed 261 times

User avatar
michel038
Posts: 436
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Batch convert - rename fails

Post by michel038 » Tue Jan 21, 2020 10:50 pm

You can use "Batch Rename" function :
First, add "Exif-Camera , Model" in the first field of this screen

Lower, use the "Replace" function and mark "use regex" : Write

Code: Select all

[^a-z A-Z0-9.]
in the first field.
This means : keep only a-z, A-Z, 0-9 characters ... (and a space, you can see it between z and A)

- Another way :

Code: Select all

 [#<>,]

This means : delete # < > and , characters

A sandbox to try and build regex expressions : https://regex101.com/

mcbrx
Posts: 18
Joined: Mon Nov 06, 2017 1:03 pm

Re: Batch convert - rename fails

Post by mcbrx » Tue Jan 21, 2020 11:38 pm

Thanks, of course it works.

But, unfortunately, renaming with Replace/Regular Expression cannot be combined with converting.
My plan is to reduce the size and copy it to another directory with changed file names.

Ok, it works now, but with 2 steps.

Post Reply