A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: [MX04] removing attached movieclip with component in it...

  1. #1
    Member
    Join Date
    Jun 2006
    Location
    Cardiff, UK
    Posts
    44

    [MX04] removing attached movieclip with component in it...

    Hi folks,

    i am currently having problems removing a movieclip. My movieclip contains a Media Display instance and i have used attachMovie to attach it, however removeMovieclip is not working for me.

    I have read in a couple of places that this could be because of the component, and that instead you could use UIObject.createClassObject() - However, it looks like the parameters for this are geared up just to create and remove a single component - my movie clip also contains a background and frame around the display which i need to attach with it.

    How can i manipulate this code to get both attached and removed??

    i just thought that maybe i could call the movieclip with attachMovie and then create the media object with createClassObject() and then destroy each in the same way, but not sure what parameters to put in the createClassObject() - can someone help, where do i assign the URL etc, with the media display offstage?

  2. #2
    Banned
    Join Date
    Mar 2007
    Location
    Albania , prishtina
    Posts
    274
    First you need to swapDepth then remove MC:

    _root.V3.swapDepths(1);
    removeMovieClip(_root.V3);

  3. #3
    Member
    Join Date
    Jun 2006
    Location
    Cardiff, UK
    Posts
    44
    perfect, it works, thanks pumi!

  4. #4
    Banned
    Join Date
    Mar 2007
    Location
    Albania , prishtina
    Posts
    274
    No Problem

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center