I have found the jsx file and compared this one with the script file for autoviewer, simple viewe and tilt viewer. The script are equal for file open and write to xml.
How can I change the script so it is sorting the files in a certain order and not random?
inputFolder.getFiles() is the troublemaker. The output of the array is unsorted, the next step is to find a function to sort the array.
O, that's dead simple. Just "fileList.sort()" and the array is sorted by name.
The script SimpleViewer.jsx is changed to:
function OpenFolder(inputFolder, outputFolder, fileType, imageSize) {
var filesOpened = 0;
//alert(inputFolder);
//alert(outputFolder);
var fileList = inputFolder.getFiles();
fileList.sort();
for ( var i = 0; i < fileList.length; i++ ) {