Referencing the expression of another layer.

Moderators: Disciple, zlovatt

Post Reply
benfrank
Posts: 2
Joined: November 2nd, 2009, 5:00 pm

So i have a somewhat lengthy expression that will be applied to all transform properties of all layers in a project. i would like to be able to easily update this expression and have that update ripple through all elements using it. my question is: is there a way to dynamically copy the expression of another layer? does the expression field itself have a name that i can use to copy it?

i want to do something like this:

Code: Select all

thisComp.layer("layer_name").transform.position.expression;
where "expression" at the end is whatever the name of the expression field is. any help would be greatly appreciated.
Mylenium
Posts: 139
Joined: July 20th, 2005, 12:07 am

No. Expressions only reference and modify property stream values, nothing else. They don't care how or why this value is there and what is producing it. Much demanded feature, but so far not come to pass. To update your expressions, use the Copy Expression only command in the Edit menu and then paste. You can of course write a full load of string parsing code to e.g. retrieve text from a global text layer and use it as the expression, but that is not particularly practical or speedy for that matter. And of course scripts...

Mylenium
[Pour Mylène, ange sur terre]
Post Reply