• 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 Set UserMaskEnabled is False

New Here ,
Jan 09, 2017 Jan 09, 2017

Copy link to clipboard

Copied

Hello :

How to let Background Mask is Close:

Before:Background1 >> After:Background2

Sample.png

I try to write this code, but is error:

var ref2 = new ActionReference();

ref2.putEnumerated( charIDToTypeID('Lyr '), charIDToTypeID('Ordn'), charIDToTypeID('Trgt') );

var desc = new ActionDescriptor();

desc.putReference( charIDToTypeID('T   '), ref2 );

desc.putBoolean( charIDToTypeID('UsrM'), false );

executeAction( charIDToTypeID('setd'), desc, DialogModes.NO );

What should I do?

TOPICS
Actions and scripting

Views

231

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

Community Expert , Jan 10, 2017 Jan 10, 2017

try {

var desc4 = new ActionDescriptor();

  var ref2 = new ActionReference();

  ref2.putEnumerated( charIDToTypeID( "Lyr " ), charIDToTypeID( "Ordn" ), charIDToTypeID( "Trgt" ) );

desc4.putReference( charIDToTypeID( "null" ), ref2 );

  var desc5 = new ActionDescriptor();

  desc5.putBoolean( charIDToTypeID( "UsrM" ), false );

desc4.putObject( charIDToTypeID( "T   " ), charIDToTypeID( "Lyr " ), desc5 );

executeAction( charIDToTypeID( "setd" ), desc4, DialogModes.NO );

} catch (e) {};

Votes

Translate

Translate
Adobe
Community Expert ,
Jan 10, 2017 Jan 10, 2017

Copy link to clipboard

Copied

try {

var desc4 = new ActionDescriptor();

  var ref2 = new ActionReference();

  ref2.putEnumerated( charIDToTypeID( "Lyr " ), charIDToTypeID( "Ordn" ), charIDToTypeID( "Trgt" ) );

desc4.putReference( charIDToTypeID( "null" ), ref2 );

  var desc5 = new ActionDescriptor();

  desc5.putBoolean( charIDToTypeID( "UsrM" ), false );

desc4.putObject( charIDToTypeID( "T   " ), charIDToTypeID( "Lyr " ), desc5 );

executeAction( charIDToTypeID( "setd" ), desc4, DialogModes.NO );

} catch (e) {};

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
New Here ,
Jan 10, 2017 Jan 10, 2017

Copy link to clipboard

Copied

LATEST

Thanks c.pfaffenbichler, that worked.

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