Copy link to clipboard
Copied
Hi, I would like some help here if it's possible. I have a script that loads a set of actions in Photoshop. Used to worked great in all version of Photoshop, except the latest. Here is the code:
function loadActions () {
app.load(new File(app.path+'/Presets/Actions/ActionsFolder/Actions.atn'));
};
loadActions ();
I repeat, this work in previous versions of Photoshop, but not in 2020. What changed?
Make sure the file exists....
function loadActions () {
var actionFile = new File(app.path+"/Presets/Actions/ActionsFolder/Actions.atn");
if(!actionFile.exists){
alert("Action file does not exist!");
return;
}else{ app.load(actionFile);}
};
loadActions ();
Copy link to clipboard
Copied
Nothing. Everything works.
Check if the file exists at the specified path.
Copy link to clipboard
Copied
Just to make sure: Does the Folder »ActionsFolder« in the Folder »Actions« actually exist?
Copy link to clipboard
Copied
Make sure the file exists....
function loadActions () {
var actionFile = new File(app.path+"/Presets/Actions/ActionsFolder/Actions.atn");
if(!actionFile.exists){
alert("Action file does not exist!");
return;
}else{ app.load(actionFile);}
};
loadActions ();
Copy link to clipboard
Copied
The problem was the wrong slash. Thank you all for your help!!!
Copy link to clipboard
Copied
.