7 Replies Latest reply on Oct 1, 2018 5:08 AM by christophero39755761

    Script to hide layer named "Draft" in multiple files.

    christophero39755761 Level 1

      new to scripting... please help! I have this script:

       

      app.activeDocument.save();

       

       

      var myWaterLayerName = "Draft";

       

       

      try{app.activeDocument.layers.item(myWaterLayerName).visible = false;}

      catch(_){alert("Can't find layer: " + myWaterLayerName);exit();};

       

      that hides a layer in the active document. how can i modify to work on all open documents?