Skip to content

Instantly share code, notes, and snippets.

@colormono
Created August 29, 2013 18:06
Show Gist options
  • Save colormono/6381382 to your computer and use it in GitHub Desktop.
Save colormono/6381382 to your computer and use it in GitHub Desktop.
Get layers names from a composition
/* Get layers names from a composition */ { app.beginUndoGroup("Demo Script"); var proj = app.project; var myFirstComp = proj.item(1); var myList = new Array(); for( var i=1; i <= myFirstComp.numLayers; i++ ){ myList[ myList.length ] = myFirstComp.layer(i).name; } var myListCorrected = myList.toString().replace( new RegExp( ",", "g" ), "\r" ); alert (myFirstComp.name + ":\r" + myListCorrected); app.endUndoGroup(); }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment