Can anyone help me with this. I don't know if this is a bug or if I am doing something wrong.
I am trying to develop a panel using CS Extension Builder ActionScript to make new layers and I can only make the TEXT layer work. This is what I'm doing: -
Code: Select all var myTextLayerRef:ArtLayer = docRef.artLayers.add();
myTextLayerRef.kind = LayerKind.TEXT;
And that works fine, creating a text layer. But when I try and create any other type of layer my script crashes. Like this: -
Code: Select all var myTextLayerRef:ArtLayer = docRef.artLayers.add();
myTextLayerRef.kind = LayerKind.CURVES;
Anyone any idea? As always, help gratefully received.
ArtLayer LayerKind does not work
ArtLayer LayerKind does not work
I have found a post saying that only kind.TEXT works in CS3. Can someone confirm that this has still not been fixed?
Is there a workaround?
Thanks.
Is there a workaround?
Thanks.
ArtLayer LayerKind does not work
I think you can only set kind to either normal or text
var docRef = app.activeDocument;
var l = docRef.artLayers.add();
l.kind = LayerKind.CURVES;
// results in "You can only change the layer's kind to text or normal"
Solution is probably using action manager code to create the layers… I don't use actionscript so I don't know from experience…
var docRef = app.activeDocument;
var l = docRef.artLayers.add();
l.kind = LayerKind.CURVES;
// results in "You can only change the layer's kind to text or normal"
Solution is probably using action manager code to create the layers… I don't use actionscript so I don't know from experience…
ArtLayer LayerKind does not work
Thanks,
According to the documentation, it is supposed to be possible.
Not sure what you mean by action manager but I'll take a look. I'm guessing you are referring to the codes generated by the script listener.
According to the documentation, it is supposed to be possible.
Not sure what you mean by action manager but I'll take a look. I'm guessing you are referring to the codes generated by the script listener.
ArtLayer LayerKind does not work
Yes that is what I mean…
"According to the documentation, it is supposed to be possible."
ah that old chestnut…
"According to the documentation, it is supposed to be possible."
ah that old chestnut…
ArtLayer LayerKind does not work
GuyOxford wrote:According to the documentation, it is supposed to be possible.
The javascript guide has said that for as long as I can remember. But it is wrong, My guess is the ActionScript guide just copied that mis-information from the javascript guide.
You don't really need LayerKind.NORMAL because that is the default. You can only set the kind to LayerKind.TEXT if the layer is a normal layer that is empty.
I am not sure about CS3 but Flex/Flash panels for CS4 can use Action Manager code.
The javascript guide has said that for as long as I can remember. But it is wrong, My guess is the ActionScript guide just copied that mis-information from the javascript guide.
You don't really need LayerKind.NORMAL because that is the default. You can only set the kind to LayerKind.TEXT if the layer is a normal layer that is empty.
I am not sure about CS3 but Flex/Flash panels for CS4 can use Action Manager code.