Quantcast
Channel: Adobe Community: Message List - Photoshop Scripting
Viewing all articles
Browse latest Browse all 27456

Re: How to duplicate the layer and than rename it ?

$
0
0

Layers have a name-property that can be changed via Script.

// 2014, use it at your own risk;

#target photoshop

if (app.documents.length > 0) {

var theDoc = app.activeDocument;

var theLayer = theDoc.activeLayer.duplicate(theDoc.activeLayer, ElementPlacement.PLACEBEFORE);

theLayer.name = "test";

theDoc.activeLayer = theLayer

};


Viewing all articles
Browse latest Browse all 27456

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>