Script for changing order of layers
i have multiple files need prepare die- cutting... art files have been built in photoshop , saved .tif... need place them in illustrator document in layer called artwork, above die-cut layer... have built action allows me pick file placed, (i need script flip order of layers put die cut layer on top)... action continues print... (then need script flip layers artwork on top , diecut on bottom), action continues save.
any appreciated
i replied question in post, i'll put answer here in hopes more helpful people have similar question in future.
function wrapper() { var docref = app.activedocument; var layers = docref.layers; var artlayer = layers["artwork"]; var thrucutlayer = layers["through cut"]; function bringthrucutforward() { thrucutlayer.zorder(zordermethod.bringtofront); } function sendthrucutbackward() { thrucutlayer.zorder(zordermethod.sendtoback); } function printcommand() { //code print file } bringthrucutforward(); printcommand(); sendthrucutbackward(); } wrapper();
More discussions in Illustrator Scripting
adobe
Comments
Post a Comment