0 Replies Latest reply on Oct 1, 2013 9:25 AM by Cartman2013

    How to get a parent's layer?

    Cartman2013

      I tried so

       

      if(app.activeDocument.activeLayer.parent.typename == "LayerSet") {

                var ls:Layer = app.activeDocument.activeLayer.parent;

      }

       

      but got an error

       

      TypeError: Error #1034: Type Coercion failed: cannot convert flash.external::HostObject@18a3a239 to com.adobe.photoshop.Layer

       

       

      app.activeDocument.activeLayer.parent.hostObjectDelegate  get null