Quantcast
Channel: Adobe Community : All Content - Edge Animate
Viewing all articles
Browse latest Browse all 9897

how to access a variable from inside another symbol

$
0
0

So i did this tutorial, Leveraging Independent Symbol Timelines created by Eliane...it's rockin, btw.  ;-)

 

All's well but now i have a symbol on the stage called mc-home.  inside of mc-home is a button called btn-go.

On the stage in composition ready there's a variable sym.setVariable("current", "mc-home");

 

This code works for a symbol that's on the stage but, how do i get this code to work on a button that's inside another symbol that's on the stage?

 

var current = sym.getVariable("current");

 

if (current != "") {

 

    sym.getSymbol(current).play("OUT");

}

 

 

sym.getSymbol("mc-something").play("IN");

 

sym.setVariable("current", "mc-something");


Viewing all articles
Browse latest Browse all 9897

Trending Articles