-
Importing file by using the script file’s path
Hello there,
I’m trying import a file by using the script’s path. I have tried like this but it doesn’t work:
var thisFile = File($.fileName);
var basePath = thisFile.path;
var resPath = basePath+”/res/”;
var paperFile = resPath+”paper.png”;
app.project.importFile(new ImportOptions(File(paperFile)));
Any ideas what’s wrong with these lines or any other way to do this?