var jsx_file = "D:\\Dev\\PyQT\\PyPS\\js_alert.jsx"; // fine //var jsx_file = "D:/Dev/PyQT/PyPS/js_alert.jsx"; // fine and prefer for cross-platform //var jsx_file = "/D/Dev/PyQT/PyPS/js_alert.jsx"; // fine and photoshop return this mydesc = new ActionDescriptor(); mydesc.putPath(charIDToTypeID("jsCt"), new File(jsx_file) ); // if the script already list in script menu, then just put the name like "MyScript" to call it instead of new file mydesc.putString(charIDToTypeID("jsMs"), "undefined" ); executeAction( stringIDToTypeID( "AdobeScriptAutomation Scripts" ), mydesc, DialogModes.NO );