• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

How to select multiple layers with UXP

New Here ,
Jan 11, 2021 Jan 11, 2021

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"
      });
}

 

 

TOPICS
Actions and scripting , SDK

Views

1.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jan 11, 2021 Jan 11, 2021

Votes

Translate

Translate
Adobe
LEGEND ,
Jan 11, 2021 Jan 11, 2021

Copy link to clipboard

Copied

LATEST

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines