A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: Loading an external swf into a mc makes the mc dissappear

  1. #1
    Junior Member
    Join Date
    Jul 2011

    Loading an external swf into a mc makes the mc dissappear


    I've tried to solve this problem and didn't really find a working solution from anywhere. That's why I'm writing it here.

    Ok then. I have this script on a specific frame and when this frame is called it should load an external movie into a mc that I have on my stage. The mc is named as holder and thumbURL down there is a vatiable which holds the name of the swf I'm trying to load into the holder.

    My problem is that the mc dissappears when I try to load this new swf into it. Could it be something with relative/static paths? Thanks in advance!

    onEnterFrame = function(){
    var mcl:MovieClipLoader = new MovieClipLoader();
    var mclL:Object = new Object();

    mclL.onLoadInit = function() {
    //preloader._visible = false;


  2. #2
    Senior Member
    Join Date
    Jun 2003
    Kent, WA
    This is normal. When you load a SWF in, it will completely replace the contents of the clip it's being loaded into. What you'll want to do is create a blank movieclip to load into, that way it doesn't replace anything.

    mcl.createEmptyMovieClip("swfClip", 0);
    Also, any particular reason that code is inside an onEnterFrame? That's definitely not something you should be doing every frame.
    Last edited by marshdabeachy; 07-05-2011 at 03:17 PM.

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