syntax to reference items in the child movie

I have a scrollpane that I am using in swf A that loads swf B using the contentPath attribute. In swf B I have a function that runs when the swf is loaded that attaches movie clips representing advertisements (1 rectangle for each ad) while looping over the number of ads available. This works just fine when swf B is run by itself, but when loaded into swf A, the function does not run, leaving me with a blank scrollpane.

What is the syntax to reference items in the child movie? The items I am looking to manipulate are on the main timeline of swf B, so I'm thinking it should be:

myScrollPane.swfB_text.txt

but that comes back undefined

Any ideas?
patGRFXSAsked:
Who is Participating?
 
Gary BenadeConnect With a Mentor Commented:
My proposed solution ID:20167796 is correct, deleting or PAQ'ing will not be fair
0
 
vickerleungCommented:
patGRFXS,

First of all, this should be a Flash question instead of Flex.

I think your problem is that loading swfB inside swfA making the _root reference of swfB changed.
I will suggest you adding the following code to swfB first frame first line.

this._lockroot = true;

Instead of thinking about controlling swfB in swfA

Cheers
Vicker
0
 
Gary BenadeCommented:
when you load something into a scrollpane you reference it using the content property, so try something like:
myScrollPane.content.swfB_text.txt
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.