Hi, I got a scriptfile (pScript) that I want to run from another script, how do I do that? Hope someone can help.
var pScript = new File(baseFolder+"\\"+myTree.selection.parent.parent.toString()+"\\"+myTree.selection.parent.parent.toString()+".jsx");
pScript.open(); ??
Thanks J
Run script from script
Moderator: Paul Tuersley
Thanks tapsystem!
Found this script which worked well for me
var baseFolder = "Z:\\00_Grafikkmaler_Master\\Settings\\(setup)";
var lScript = new File(baseFolder+"\\"+"PromoLauncher.jsx");
var lText = "";
// Load the script's contents into a string
lScript.open("r");
while (!lScript.eof)
lText += lScript.readln() + "\r\n";
lScript.close();
// Evaluate the script's contents
eval(lText);
Found this script which worked well for me
var baseFolder = "Z:\\00_Grafikkmaler_Master\\Settings\\(setup)";
var lScript = new File(baseFolder+"\\"+"PromoLauncher.jsx");
var lText = "";
// Load the script's contents into a string
lScript.open("r");
while (!lScript.eof)
lText += lScript.readln() + "\r\n";
lScript.close();
// Evaluate the script's contents
eval(lText);