Copy link to clipboard
Copied
I'm using batchplay to select layer and I wanted to make this function take array of layers name and select them all but I still don't know how to add target to batchplay. any help is appreciated.
async function testSelect(){
const batchPlay = require("photoshop").action.batchPlay;
const result = await batchPlay(
[
{
"_obj": "select",
"_target": [
{
"_ref": "layer",
"_name": "Rectangle 2"
},
],
"makeVisible": false,
"_isCommand": false,
"_options": {
"dialogOptions": "dontDisplay"
}
}
],{
"synchronousExecution": false,
"modalBehavior": "fail"
});
}
Copy link to clipboard
Copied