ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Select all guide layers from active comp without selecting the layers in AE scripting

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Luqman Ameer
Select all guide layers from active comp without selecting the layers in AE scripting
on Feb 16, 2020 at 4:34:59 am

Hi, i have an active comp "compname" and have more than 130 layer of different types 'guide, 3d, label red' how can i select it from all layers only guide or 3d or label red.
Please tell me each type separately

Thanks.


Return to posts index

Dan Ebberts
Re: Select all guide layers from active comp without selecting the layers in AE scripting
on Feb 16, 2020 at 3:30:36 pm

This should work:


var myComp = app.project.activeItem;
for (var i = 1; i <= myComp.numLayers; i++){
myComp.layer(i).selected = (myComp.layer(i).threeDLayer || myComp.layer(i).guideLayer || myComp.layer(i).label == 1);
}



Dan



Return to posts index

Luqman Ameer
Re: Select all guide layers from active comp without selecting the layers in AE scripting
on Feb 17, 2020 at 4:51:20 am

Thanks it works perfectly what i need.
The platform creativecow is amazing.

I have some other issue, i want to move timeline indicator to 150 frames forward from current time, how can i trigger this via script.
Thanks.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2020 CreativeCOW.net All Rights Reserved
[TOP]