2014-02-05 37 views
0

任何人都可以帮我找出为什么这不会加载在我的SWF?我没有收到任何错误。loadClip as2不加载swf

var my_mcl:MovieClipLoader = new MovieClipLoader();//Used to load the image 

button1_mc.onPress = function() 
{ 
my_mcl.loadClip(B.swf,container_mc);//loading a movie into a container movie clip (just an empty mc on the stage) 
trace("a") 
}; 

button2_mc.onPress = function() 
{ 
my_mcl.loadClip(B.swf,container_mc);//loading a movie into a container movie clip (just an  empty mc on the stage) 
    trace("b") 
}; 

var mclListener:Object = new Object(); 
my_mcl.addListener(mclListener); 

回答

0

我可以看到在你的代码中的问题的唯一的事情是,你要加载的URL的SWF应双引号包围:

my_mcl.loadClip("B.swf", container_mc);