Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions copy markers from layer markers to comp markers

  • Simone Maldini

    November 5, 2020 at 5:05 am

    Hi Dan, i am new in expression and it is the first time that i write and apply a script. i found your script for move markersLayer to markersComp. I need to change the target: create a compMarker for each inPoint layer selected that i have in the comp. I tryed to change your script but the new one works only for the first selected layer.

    Can i ask you to help me understanding where is the error and how can i fix it?Thank you very much.

    var theComp = app.project.activeItem;

    var theLayer = theComp.selectedLayers[0];

    var theTimes = [];

    for (var i = 1; i <= theComp.numLayers; i++){



    for (var i = 1; i <= theComp.numLayers; i++){

    theComp.layer(i).selected = false;


    for (var i = 0; i < theTimes.length; i++){

    theComp.time = theTimes[i];

    app.executeCommand(app.findMenuCommandId(“Add Marker”));


  • Dan Ebberts

    November 5, 2020 at 8:03 am

    It’s easier to do now that scripting has access to comp markers. Something like this should work:

    var theComp = app.project.activeItem;

    var theLayers = theComp.selectedLayers;

    var theMarker = new MarkerValue("");

    for (var i = 0; i < theLayers.length; i++){

    theMarker.comment = theLayers[i].name;



  • Shashank Raghu

    September 21, 2021 at 11:49 am

    Hi Dan, is there a way to copy markers from one layer and move them to another layer?

  • Andrei Popa

    September 21, 2021 at 12:36 pm

    Here is a script made by Jeff Almasol, that could be downloaded from his website,, when it was not offline.

Page 3 of 3

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy