Quantcast
Channel: Adobe Community: Message List - InDesign Scripting
Viewing all articles
Browse latest Browse all 37788

Re: Combine two layer names in one command

$
0
0

Gr Kosta,

 

Do you mean that you want to be able to undo both layer setting changes in a single undo? If so, this can be done using app.doScript using UndoModes.entireScript:

 

myDokument = app.activeDocument;
app.doScript(ChangeLayerFunc, ScriptLanguage.javascript, undefined, UndoModes.entireScript, "Your Undo Text");

function ChangeLayerFunc()
{          myDokument.layers.item("Layer 1").visible = true;     myDokument.layers.item("Layer 2").visible = true;
}

 

I hope this helps!

 

-- Jim


Viewing all articles
Browse latest Browse all 37788

Trending Articles



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