So I have gotten this far:
// "-normalize -resize 1024x768",
var strOrigName = document.properties.name;
var tmpName = "resized_" + document.properties.name;
document.properties.name = tmpName;
var rImage=document.transformImage("image/jpeg","-normalize -resize 1024x768", document.parent);
if (rImage){
document.properties.name = strOrigName;
document.save();
//document.remove();
}
The documentation does not seem to give any way to access specific known docs. So I can rename and save the new resizedimage, but cannot figure out how to delete the old file nor can I figure out how to rename the new document. I am very familiar with javascript and maybe I am too clouded by regular web scripting to see how this works.
The errors I get state nodeRef is required, but I cannot find anyway to obtain a nodeRef.