Quantcast
Channel: Adobe Community : Popular Discussions - Photoshop Scripting
Viewing all articles
Browse latest Browse all 12244

Photoshop JavaScript fill layer creation question

$
0
0

You can probably guess what I'm trying to do by this snippet:

var docRef = app.activeDocument;  var layerRef = app.activeDocument.artLayers.add(); layerRef.kind =LayerKind.SOLIDFILL;

I want to script the creation of a fill layer (and then later designate color, remove mask, etc). I get this response from the ExtendScript Toolkit: "You can only change the layer's kind to text or normal"

I would have thought that there would be a way to pass arguments of some sort to the add()method of artLayers?! Am I missing something really simple? Thanks.

I know this can be done with actions but I would like to learn how to do this (seemingly) very simple task and build on it to create more complex, useful scripts.

Also, i don't know if this is important but I'm running Ps CC15, ES toolkit 4, and using script reference CC14


Viewing all articles
Browse latest Browse all 12244

Trending Articles



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