Copy link to clipboard
Copied
Hello, Can anyone help me with this? Below code is working fine on my one machine but not working on other machine. Even everthing is just same as of machine Ist on the 2nd machine. I have created config.js file with below code at C:\Program Files (x86)\Adobe\Acrobat Reader DC\Reader\Javascripts
Condition if(typeof(mySaveAs) == "function") is returning true on machine 1 and returning false on machine the 2nd.
please help me out.
var mySaveAs = app.trustedFunction(
function(oPdf,cPath,cFlName)
{
app.beginPriv();
cPath="/c/temp/";
cPath = cPath.replace(/([^/])$/, "$1/");
try{
oPdf.saveAs(cPath + cFlName);
}
catch(e){
app.alert("Oops!! Something went wrong.");
}
app.endPriv();
}
);
[Moved from Community Help to Acrobat Reader.]
Copy link to clipboard
Copied
Can you guys please help me with this.
Copy link to clipboard
Copied
1. Check the JavaScript console for messages.
2. You must use your own made up name for this function. Using the name everyone else uses is a security risk.
Copy link to clipboard
Copied
If the if-condition returns false it means the script is not installed correctly, or contains an error.