Welcome Dialog

Welcome to the Community!

We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.


parent.thisComp.name

Community Beginner ,
Feb 19, 2020 Feb 19, 2020

Copy link to clipboard

Copied

expression 

"parent.thisComp.name"

 

I want get name from the parent composition. What can i do to make magic happen?

TOPICS
Expressions

Views

794

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Adobe Community Professional , Feb 19, 2020 Feb 19, 2020
There is no such thing. Since a pre-comp can be used a million times in other compositions it can have infinitely many parents. That's a simple logic issue. You have to explicitly reference the parent comp or use some strict naming convention and string processing to filter out whatever comp you want to address. Mylenium

Likes

Translate

Translate
Adobe Community Professional ,
Feb 19, 2020 Feb 19, 2020

Copy link to clipboard

Copied

There is no such thing. Since a pre-comp can be used a million times in other compositions it can have infinitely many parents. That's a simple logic issue. You have to explicitly reference the parent comp or use some strict naming convention and string processing to filter out whatever comp you want to address.

 

Mylenium

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Mar 24, 2021 Mar 24, 2021

Copy link to clipboard

Copied

LATEST

But, but, but.. if it's not the parent. I mean it's not the controller of the item contained within it is a container. So can the comp or layer inside link to the 'container' comp property. The container comp may change but the parameter exists in each. For example, a comp within a comp contains a text layer. That text layer needs to be named the name of it's 'grandfather' comp. So how might one code the sourceText to say read the name of whatever comp is 2 levels above? for example. It's not exactly a parent in the same relationship as a null object, but the relationship will be there if the comps are stacked.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines