ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Dynamic layer targeting

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Ross McDowell
Dynamic layer targeting
on Oct 9, 2008 at 12:47:59 pm

Hello all!

Quick question for you guys, I am messing about with an expression...and I want to do something along the lines of the following:

thisComp.layer("layer[index+1]").transform.position;

Meaning that I want to be able to target the layer that is below the layer with the expression...how do I do this and is this even possible?

It will make things easier for me as I can just duplicate pairs of layers and have it position itself for me...

Thanks

Ross

Ross McDowell
Animation Student


Return to posts index

Eric Sanderson
Re: Dynamic layer targeting
on Oct 9, 2008 at 2:21:56 pm

and are you saying that code isnt working?..if so try this...

thisComp.layer(index+1).transform.position.

in your " layer(" ") " you were telling AE to look for a layer named "layer[index+1]", instead of telling it to look at the actual index.



Return to posts index

Steve Bentley
Re: Dynamic layer targeting
on Apr 19, 2018 at 4:45:41 am

I just stumbled on this and thought I would update and correct it. The syntax for the above is incorrect in both posts. It should be
thisComp.layer(index+1).position;



Return to posts index

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