Skip to main content
Participating Frequently
February 14, 2009
Question

Can't instantiate a symbol using Flash CS4 and AS 2! Help Please!

Hi. I have just started using AS 2 to create an animation for mobile.
I created a MovieClip symbol (mc_IntroText) which is in the library (not on the stage).
In the Actions panel I tried to instantiate the symbol as follows: var intro:mc_IntroText = new mc_IntroText();
but i keep getting the following error message...."The class or interface ' mc_IntroText' could not be loaded".
Any suggestions would be great!
Thanks.
Ce sujet a été fermé aux réponses.

1 commentaire

Inspiring
February 14, 2009
>>var intro:mc_IntroText = new mc_IntroText();

You said you're using AS2 but that is AS3. In 2 you'd use the
MovieClip.attachMovie method:

If you have code on the timeline, and want to attach it to root you'd do:

var ref = this.attachMovie("linkageName", "newName", depth);

where linkageName would likely be mc_IntroText.


--
Dave -
www.offroadfire.com
Adobe Community Expert
http://www.adobe.com/communities/experts/