Thompson
03-25-2008, 01:54 PM
Hello, folks!
I have a doubt that is making me mad.
Suppose that I have a variable defined in the main timeline, like this:
var str:String = "foo";
Suppose too that I have a movie clip called mc1 inside the same keyframe of the variable instanced before ( I think this is not important for the test ).
Here is the doubt: How do I access the variable str from movie clip mc1??
I tried this, without success:
trace( stage.getChildByName("root1").str );
trace( stage.root.str );
trace( stage.getChildByName("root1").getChildByName("str") );
Why it does'nt work??
Thanks for any help!!!
I have a doubt that is making me mad.
Suppose that I have a variable defined in the main timeline, like this:
var str:String = "foo";
Suppose too that I have a movie clip called mc1 inside the same keyframe of the variable instanced before ( I think this is not important for the test ).
Here is the doubt: How do I access the variable str from movie clip mc1??
I tried this, without success:
trace( stage.getChildByName("root1").str );
trace( stage.root.str );
trace( stage.getChildByName("root1").getChildByName("str") );
Why it does'nt work??
Thanks for any help!!!