AE script -replacing layer with other footage
  • Hi all,
     I'm just getting started with scripting for after effects. I'm wondering if there is a way for replacing layers comments with another footage  when they run the script. 
    So far all I can do is the script down.
    var comp = app.project.activeItem;
    var layer = comp.selectedLayers;
    if(comp && comp.selectedLayers.length > 0)
    ().replaceSource(layer)};
    place give me some guides.