Copy link to clipboard
Copied
Hi Friends, I'm new to After effects scripting. Is there anyway to find the duplicate comp using comp name?
Thanks in advance
Copy link to clipboard
Copied
This simple example should find all the comps named "Comp 1":
var compName = "Comp 1";
var comps = [];
for (var i = 1; i <= app.project.numItems; i++){
if ((app.project.item(i) instanceof CompItem) && (app.project.item(i).name == compName)){
comps.push(app.project.item(i));
}
}
alert(comps.length);
Dan
Copy link to clipboard
Copied
Hello,
Is it possible to do that just by selecting a comp and launch a script to find comps with the same name ?
(to find comps by name, you just have to use the search bar)
Thx
Philippe