Can i assign a child state to a movie clip that is already placed on stage

Hello
Is it possible to add a child state to a movie clip that is
already placed on stage,
i need to do this so i can move the movieclip to the top of
the display list.
thanks for the help
mt

"The objects i want it to appear above are loaded swf's onto
the same main stage."
Aha, this is where things can get confusing. The terminology
between the Flash Authoring tool and ActionScript is not
consistent.
In ActionScript, the Stage is the top most DisplayObject. You
probably get that.
In Flash, the canvas that is often referred to as "the stage"
is not the Stage object of ActionScript, rather the Flash stage is
a DisplayObject class called MainTimeline (or if you assign a
document class, it's that class), which is the first and only child
of the ActionScript Stage object. It's the only child unless, of
course, you add something else to the ActionScript Stage object at
runtime... like a loaded swf. ;)
So in other words, if you are doing anything like this:
stage.addChild(myLoadedSWF)
You are actually putting myLoadedSWF above the MainTimeline
object, which is the entire Flash timeline. There's nothing wrong
with that, but in this case it means changing the depth of things
inside the MainTimeline is not going to change the fact that the
MainTimeline itself is below myLoadedSWF.
Most likely the simplest solution is to add your loaded SWFs
to the property "root", not stage. root can refer to different
things in different places, but most of the time it refers to the
MainTimeline, and if I had to guess I would say it almost certainly
does in your case. Note that the "root" property is typed as a
DisplayObject, not a DisplayObjectContainer, so addChild (which is
a DisplayObjectContainer method) will not be recognized unless you
typecast to DisplayObjectContainer or a subclass of
DisplayObjectContainer, like Sprite or MovieClip:
MovieClip(root).addChild(myLoadedSWF)
Also note that, unlike AS2, in AS3 it's very easy to simply
add your loaded SWF below existing objects you create in Flash. You
can use addChildAt(obj,0) for instance to add it to the very
bottom.

Similar Messages

  • How can I load an external SWF into a movie clip that's inside other movie clip?

    Hi.
    I creating my first flash (actionscript 3.0) website but I'm
    stuck with a visual effect I want to create.
    I have a window on my website called contentWindow. Every
    time you click a button this window is supposed to leave the stage,
    load the requested content and return to the stage.
    The sliding window is a movie clip with 83 frames, 21 to
    enter the stage, 21 to leave the stage again, 20 for nothing (its
    just to simulate the loading time) and 21 to return to the stage.
    Now my goal is, when the user clicks on a navigation button,
    the window exits the stage, loads an external SWF with the content,
    and then returns to the stage.
    I've the "window" movie clip with an instance name of
    "contentWindow". Inside there is another movie clip with an
    instance name of "contentLoader". The content that the user
    requested should appear inside the "contentLoader".
    Now, when the contentWindow leaves the stage, I get this
    error message:
    quote:
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at rwd_fla::MainTimeline/trigger()
    If I switch
    "contentWindow.contentLoader.addChild(navLoader);" for
    "contentWindow.addChild(navLoader);" it works fine, but the
    external SWF doesn't move with the window.
    How can I load an external SWF into a movie clip that's
    inside other movie clip?

    Hi,
    Recently, I have been putting together a flash presentation.
    And I am just wondering if the following might help you, in your
    communication with the said swf file:
    loader.contentLoaderInfo.addEventListener(Event.COMPLETE,
    onComplete);
    function onComplete(event:Event):void
    event.target.content.thinggy_mc.y -= 100;
    Not the best example, but this allows you to target a mc
    within an external swf file. I think if you look up this code, you
    will have an answer ;)
    Kind Regards,
    Boxing Boom

  • How can I convert my animation into a working movie clip that can be used with a new scene?

    Hello all,
    First and foremost, I AM A TOTAL FLASH NOOB. I want to preface this and make it incredibly clear how new this all is to me. I LITERALLY started using flash this morning; that is precisely how new I am.
    With that being said I am going to do my best to explain what I'd like to do.
    I have created an animation of a spider moving its legs back and forth. I want to be able to combine all of the layers into 1 simple animation that can be imported into new flash scenes with the animation exactly how it stands. I have figured out how to convert the whole animation into a symbol AND I have figured out how to import the movie clip from the library. However, herein lies my problem. When I open a new flash scene and import my animation, I play it and it does nothing at all. It's just the static image of the spider I created with no movement.
    I've spent the last couple hours trying to figure out (and doing my own research) what I have done or didn't do to get to this point. I'd be willing to bet I am just going about the entire process incorrectly and I'm simple overlooking a basic facet of the program.
    Any insight to fix my ignorance is greatly appreciated.
    (P.S. Hell, I don't even know if I am using the correct terminology so for all I know I am confusing every person who has taken the time to look at my question. If I am using incorrect terminology please correct me to avoid future hang ups. Thank you.)

    Ned! This totally worked! Thank you! I knew there was a tiny piece of this whole thing that was preventing me from making everything work. Unfortunately as my luck would have it, although I have the movieclip working the spritesheet converter I'm using now no longer recognizes the movie clip. The converter says there are 7 frames in the animation, but doesn't display any working sprites. Just a blank sheet. Frustrating to say the least.
    I'm just going to throw everything out on the table here:
    This is the video tutorial i'm using to convert my animation into a spritesheet. I've done the steps exactly as directly up until the point I actually click "Begin Conversion." When begin conversion is selected, it shows the movieclip exists on the bottom left underneath "list of movieclips" but doesn't actually show any individual sprites.
    Here's the simple sprite converter I am using.
    The irony of this whole situation is that you have successfully helped me make a working movieclip (which was the important piece), but the converter no longer recognizes it. Whereas before, it would at least show the image on the 1 frame of animation it had.
    If you wanted to to take a stab at it and see if you can successfully get it to work I'd be appreciative. If not, I totally understand as you have already been incredibly helpful and have my eternal gratitude for getting me this far. These animation programs can be quite overwhelming when they so vastly differ from one another. Don't even get me started no Anime' Studio Pro.

  • How can I put a slideshow on automatic with movie clips longer than 2 minutes?

    How can I put a slideshow on "automatic" with movie clips that are longer than 2 minutes?

    Inspector > Animate > start transition to Automatically and set the delay to the duration of the video clip.

  • Flex won't display a child of a container movie clip

    I have a Container Movie clip called frameContainer in wich I load new Frames( a symbol from flash), with this function:
                 var i:Number=0;
                frameContainer.x=48;
                xPos=0;
                do
                    frames.push(new Frame());
                    frameContainer.addChild(frames[i]);
                    slideshow.push(false);
                    frames[i].index=i;
                    frames[i].f.width=frameWidth;
                    frames[i].f.height=frameHeight;
                    frames[i].x=xPos;
                    frames[i].y=0;
                    xPos+=frames[i].f.width+10;
                    frames[i].f.addEventListener(MouseEvent.MOUSE_UP,fMouseClickOnFrame,false,0,true);
                    i++;
                }while(xPos<200)
                frameNumber=i;
                this.addChild(frameContainer);
    The previous function works great.And I have a function called addNewFrame() which adds a new Frame at the end:
           private function addNewFrame():void
                frames.push(new Frame());
                frameContainer.addChild(frames[frameNumber]);
                frames[frameNumber].f.width=frameWidth;
                frames[frameNumber].f.height=frameHeight;
                frames[frameNumber].x=xPos;
                frames[frameNumber].index=frameNumber;
                xPos+=frames[frameNumber].width+10;
                frameNumber++;
                frames[frameNumber-1].f.addEventListener(MouseEvent.CLICK,fMouseClickOnFrame,false,0,true );
    But, for some reason, the new frame can't be seen. When I type just
    addChild(frames[frameNumber]);
    (instead of  frameContainer.addChild(frames[frameNumber]) )
    it works great. Also I can access the new frame with the getChildAt method, the only, and biggest problem is that I can't see that new frame when I add it as a child of the frameContainer movie clip.
    Can someone please help

    Same thing in iMovie '09 I just noticed. But it renders, so I guess who cares.

  • I have numerous music movie clips that I have not purchased through iTunes, can I stream these "home" movies to apple TV? And if this is not possible, is there another complete program available that I can purchase to have my music movie clips stream to a

    I have numerous music movie clips that I have not purchased through iTunes, Is it possible to stream these "home" movies using iTunes to apple TV?
    And if iTunes will not allow it, is there another complete program available that I can purchase to have my music movie clips stream to a TV and/or another computer?
    Any help would be appreciated. Thanks

    Thanks, Winston C, I've actually tried everything you suggested. I'm thinking now that the Home Sharing problem likely is related to Bonjour--I've seen several people mention this with similar (but not identical) problems. The solution that seems to work for some people is to uninstall and reinstall Bonjour. Frankly, I don't want to go through the trouble given that the iOS 7 release is imminent.
    One thing that I haven't tried is resetting the ATV to factory settings. I'll give that whirl.
    Thanks for your advice!

  • When I opened iweb it opened as a file I deleated. I have a published website with godaddy and would like to update. How can I open the existing iWeb app to the site that is already published?

    When I opened iweb it opened as a file I deleated. I have a published website with godaddy and would like to update. How can I open the existing iWeb app to the site that is already published?

    You cannot retrieve the already published site as iWeb CANNOT open it - it has no import facility.
    You need your domain.sites file, which you can find under User/Library/Application Support/iWeb/domain.sites.  You do not need any kind of account for this because it is your domain.sites file that resides on the hard drive of your Mac anyway.  Find this file and you can alter your website.
    Use a spotlight search to try and find it and if this does not work you can download something called Find Any File.  If you really can't find it, then you'll have to start from scratch because iWeb cannot open a site that is already published.

  • How can I get Firefox to search my computer for plugins that are already there?

    How can I get Firefox to search my computer for plugins that are already there?
    Adobe's Flash player is already on my computer from IE 8. How can I get Firefox to see that it is already on my PC and use it so I don't have to download it again and possibly create other problems. Also, in my efforts to download Flash, Firefox activated IE which made me concerned that proceeding WOULD cause problems our just leave me where I am now where IE can use Flask but Firefox cannot.

    Internet Explorer uses a ActiveX version of the Flash player plugin as it does not work with other browsers.
    Download the Plugin-based browsers version from https://www.adobe.com/products/flashplayer/distribution3.html and make sure Firefox is closed when you install it.

  • I have 3 consecutive movie clips that I am trying to drop into the drop zone but it only recognizes the first one and only produces the firts one in a DVD. How can I drop all three  movie clips into one drop zone

    On IDVD, I have 3 consecutive movie clips that I am trying to drop into the drop zone to create a DVD but it only recognizes the first one I dropped and only produced the first one in a DVD. How can I drop all three  movie clips into one drop zone.

    I have had some luck doing the following: Export each clip from imovie as a quicktime clip. Open iDVD and create a new project. Import a few stills into iDVD and then click on the button that gets created to get into the screen where the individual slides appear. Drag each quicktime into that screen and arrange in the order you want. You can then delete the stills. The button that appeared when you dropped in the stills will launch a complete show.

  • Elements 11 the instant movie "In Loving Memory" mixs up the Photo/movie clips that i put in.  Can this be corrected?

    Elements 11 the instant movie "In Loving Memory" mixs up the Photo/movie clips that i put in.  Can this be corrected?

    Howardok
    Premiere Elements 11 on what computer operating system?
    You should be able to right click the finished Instant Movie on the Timeline and select "Break Apart Instant Movie" to do just that.
    Then open all the tracks, expand the Timeline with the -+ slider above the Timeline, and edit your Instant Movie.
    Please review and consider. If you have questions or need clarification on the above, please do not hesitate to ask, but supply more details.
    Thank you.
    ATR

  • How do I assign a mouseclick event Listener to a simplebutton already nested in a movie clip when it's dropped on stage?

    I'm trying to assign a mouseclick event listener to a simplebutton nested within a movie clip's later frames, starting at frame 2 and up. This card, however, is not added to my game until later, and when the player clicks on it/turns it over.
    There are four files involved in this program:
    #1 The main actionscript file, which corresponds to
    #2 my dreamQuester .fla file.
    #3 my artifactCard file movieClip's corresponding .as file,
    #4 my combo1.as file corresponding to a an instance of a simpleButton named combo1 that is already
    nested --and this instance is already named-- inside/as a child of said artifactCard movieclip.
    What I've done so far isn't working:
    In my main dreamQuester.as file, when a player clicks on an artifactCard, its MOUSE_DOWN event
    listener takes them to this function (clickArtCard), where the trouble is at:
    // player clicked on the artC card--which is a child of posArt1 on stage--to turn card over:
            function clickArtCard(a_event:MouseEvent) {
                var thisArtCard:artifactCard = (a_event.target as artifactCard);
                thisArtCard.gotoAndStop(unclickedArt1);  // go to frame number of artifact
                                    // card where combo1 button is.
                thisArtCard.removeEventListener(MouseEvent.CLICK,clickArtCard);
                thisArtCard.buttonMode = false;
                trace("combo1.combo is:" + combo1.combo);
                trace("posArt1.artC.combo1 is:" + posArt1.artC.combo1);
                posArt1.artC.combo1.addEventListener(MouseEvent.MOUSE_DOWN, comboClickedWHO);
    when the artC card--the static public instance of artifactCard--is clicked, it only gets to the
    trace("posArt1.artC.combo1 is:" + posArt1.artC.combo1); which returns this error message:  
    TypeError: Error #1010: A term is undefined and has no properties.
        at MethodInfo-61()
    So do how would I declare a static public variable of this simpleButton at the start of my main .as
    file to make it defined to get a mouseDown actionListener into my pre-existing-and-named-instance
    combo1 simpleButton?
    perhaps there is a way, while the debug movie program is running, to click on the simpleButton and see exactly
    what it's parent heirarchy is, to see the name of all parents above the simpleButton incase they are
    different then what I think?
    (just in case, I was hoping to squeeze a zip file containing these files to be less than 9MB incase someone was willing to look at my files to see what I've done so far, but 9 megs is just too big! even though all graphics I've imported where turned into vector graphics with trace bitmap. I wish there was a way to check the file size of each symbol in Flash CS4, here...)
    Thank you so much for any help!
    ~Ethan

    Just use a
    stage.addEventListener(KeyboardEvent.KEY_DOWN, keyPressed);
    function keyPressed(event:KeyboardEvent):void {
         //trace(event.keyCode);
         if(event.keyCode == ???){
              // play the sound
    Where I show the "???" you would replace with the keyCode for the key you want pressed for that sound.  To determine the keyCode you can use the trace line that I have commented out.
    Note that when testing in Flash you often need to disable the keyboard shortcuts in the Flash Player in order to be able to use alot of the keys.  You will find this option in the Control menu options in the player.

  • Keeping "state" with many movie clips

    In one frame (Frame A), I've dynamically attached many movie
    clips for a tile-based game. This happens in the init function of
    that frame. If I move to another frame (Frame B) temporarily (to
    display something else), it looks like I need to remove or unload
    all of the movie clips so that they don't show up on Frame B. Is
    that the only way to not have them show? The problem is that when I
    return to Frame A, I would like it to have the same state
    (positions of objects, etc.) as when I left it. What is the best
    way to accomplish this?
    As an alternative, I suppose I could draw something on top of
    the screen (higher z order) and mask what is below and then remove
    what was draw on top when I'm finished with it. I would prefer to
    figure out a way to accomplish it the first way, though, because I
    can use this for other things as well.
    Does anyone have any advice on this?
    Thanks!

    I understand that you can remove one parent instead of many
    children in this way, which is good from an efficiency standpoint.
    Beyond that, I was ideally looking for a way to basically "freeze"
    the action on Frame A and return to it. I assume that, even with a
    parent-child scenario, I would still need to loop through all of
    the children and save their states (because just checking the
    parent attributes isn't going to get at this information). I was
    just asking if there was any easier way. It would be nice to be
    able to go to another frame - maybe on another level - and then
    come back to Frame A and pick up where I left off - just hopeful
    thinking, I guess.

  • Can I register a new iphone to an apple ID that is already registered to another iphone?

    I managed to disable my iphone so went through the process of restoring it, then it asked me to enter my apple ID that was originally used to set up the phone. However it isn't having any of it and says '[email protected] cannot be used to unlock this iphone' so the phone is now pretty much useless.
    So i'm planning on buying another iphone 4s but I have a few questions.. Can my CURRENT apple ID be used to register my phone (same ID i've used all along just changed the email) that's already registered on my old iphone or will I have to create a new one? I have no option to delete the current owner settings as I never created an icloud account. thanks for any help!

    "am I still able to register another phone to the same ID?"
    Yes.
    ") that I do end up creating a new apple ID "
    This will cause complications.  i do not recommend this.

  • Can dynamic text links (XML) pass arguements to movie clips?

    I have a dynamic text field that i'm pulling a XML file into,
    but I need the URL links within the XML to control a movie clip.
    I've read that you can pass an arguement inside flash from within
    the XML doc but i'm not positive how it would be done.
    Any love on this one?

    Hmm, this leaves a couple questions... Where would I put the
    script/function, inside the <a href> tag? That could get out
    of hand... like in-line CSS styles. And I have a URL node within
    XML set-up so I don't know if this solution would work.

  • Can I copy a single frame from a movie clip and paste it over a bad blank frame in the same clip?

    I have two frames in my video clip that are solid green.  I would like to copy the last good frame and paste over the green video frames for the movie to play without the green frames popping up. Is thispossible?

    You can install an App called MPEG Streamclip or you can simply pull up the clip in full screen and take a screen shot using (command+shift+3) or using (command+shift+4) to click and drag to create a box around what you would like to take a snap shot of.

Maybe you are looking for

  • Preview and Print restrictions in PDF

    Hi there, I bought the Adobe Type Basics pack, and I would like to use one of the fonts that has the Preview and Print license. The Preview and Print license states that "Preview & Print allows the font, either fully or as a subset, to be embedded in

  • My iMessage will not activate with my phone number when I recieved a new apple ID.

    I made a new apple ID because my old one would not let me download any new apps from the app store. Everything works great with my new appleID EXCEPT it will not let me use imessage with my phone number. I have tried network resets, turning on/off th

  • Why not create a command

    why not create a command that shows you how many miles the paket travel to distination . that way you can figure out your lentency right there base on the distance.. show distance x.x.x.x it will show you the distance from b/w the interface you are s

  • How to back up to DVDs

    Hello all, I have DVDs and want to back up my computer, such as my photos, and music, and anything else that is recommended to backup, which I am not sure what that would be. I don't have all that much to backup, I don't think. I do not have very muc

  • HT4623 Hye my device is 4.3 how can i update to ios7

    Hye im using iphone ios 4.3 how can i upgrade it to ios 7 by internet in my device.thankio