PDA

View Full Version : access child of a movieClip


MasK
12-21-2010, 06:06 AM
Hi,

Is there a way to access the child of a selected movieClip in JSFL.

ie, i can access the selected movieClip using fl.getDocumentDOM().selection[i]. Now i also want to access the child of this movieClip.

My aim is to give instance name to all the movieClip in an FLA

MasK
12-28-2010, 08:12 AM
some one please help....

daveystew
12-29-2010, 01:01 PM
I'm pretty sure you have to go into the movieclip using edit mode, make your rename, then come out again.

animatorgeek
01-25-2011, 08:32 PM
I don't thin I've tried this before, but it should be possible to access get the LibraryItem instance that the MovieClip refers to, get that SymbolItem's timeline, and access its children from there.

So if your MovieClip is called bob, it would be like this:

bob.libraryItem.timeline.layers[0].frames[0].elements[0]

(assuming you only have one item on one layer in your MC).