Access violation in in module 'js32.dll'

Advanced Renamer forum
#1 : 09/01-19 04:40
BJ
BJ
Posts: 1
Running version 3.84 and i regularly get the error "Access violation at address ... in module 'js32.dll', Read of address ..."

I'm using a custom script that reads exif data. My pictures are from different sources so I wrote a script to pull from multiple exif tags and choose the earliest one. As reported by others over the past few years, if I only have a few files it seems to work, but inevitably I'll get the error. I then have to close down and reopen. Makes the tool extremely difficult to use given I have thousands of pictures to rename.

Any suggestions?

Bob


09/01-19 04:40 - edited 10/01-19 02:46
#2 : 20/01-19 14:47
giov
giov
Posts: 3
Reply to #1:
I've encountered the same issue. Instead of using a script to pull exif data to a variable, try temporarily writing the tags in question directly in the file name using the Add method (for example <ExifTool:imageHeight>), and then spliting the filename, and isolating it until you're only left with what you need. Then you can manipulate it like you would have originally with your old method.

I needed a script to order the way resolutions are written in filenames, so the biggest value is always first (instead of 1024x1768, i wanted 1768x1024).
I originally scripted it like this (but i got the dll error):
a=<ExifTool:ImageWidth>
b=<ExifTool:ImageHeight>
if ( a > b ) { rezord = a + "x" + b ;}
else { rezord = b + "x" + a ; }
return '[' + rezord + ']' + item.newBaseName;

What I ended up doing was:

//the name looks like 01_[1024x768]_name[publisher]
var part = item.newBasename.split(']');
var firstPart=part[0]; // part[1] = filename after resolution
var nrAndRes = firstPart.split('[');
onlyRes=nrAndRes[1]; //nrAndRez[0]=number
dimension=onlyres.split('x');
a=Number(dimension[0]);
b=Number(dimension[1]);

if ( a > b ) { resOrd = a + "x" + b ;}
else { resOrd = b + "x" + a ; }
return nrAndRes[0] + '[' + rezOrd + ']' + part[1] + ']' + part[2];

Hope this gives you an idea of what to do.

----------
Sorting is a hoarder's nightmare!


20/01-19 14:47