flash actionscript:
Does anyone know how I can load an external .swf file into my parent file? I have tried to use loader actionscript but think I am using the incorrect script or putting it in the wrong place? If anyone can tell me the script and where to/how to use it that would be amazing? Thanks :grin;
Ok so i have finally figured it out, and another problem has arisen!! i've used the stop command to allow the external movie to load. now when it unloads it wont run the original movie as there is a stop command, is there a way when it unloads and goes back to the parent swf that i can bypass the stop action and tell it to go elsewhere in the parent swf??
How are you unloading/removing it? E.g. did you put some something like: this.removeMovieClip(); in the last frame of the child swf etc? If so and if you loaded it as a child of the other swf that you used the stop() command in, then just before you issue the this.removeMovieClip() code, you could put _parent.play(); or _level0.play(); I think that should work.
thanks GWD! I am using the unloadMovieNum(); command, i have loaded the child into level 5 of my parent swf. the parent has multiple scenes this one with a layer with a stop(); action and another layer with the loadMovieNum("portfolioone.swf", 5); script. it loads the child perfectly. The child has a number of pictures in it and a back button at the end. I have been adding the on (release) { unloadMovieNum(5); } script to the button which unloads the child but stops because of the stop action in the first frame of the particular scene within the parent. I want to be able to add a script to this button which will take me back to a labeled frame in a particular scene of the parent, I tried the this.removeMovieClip(); but doesn't seem to be working for me, Thanks for the reply, hope you can help me further??
Is the "parent" on level0? if so try changing the button code to : on (release) { _level0.play(); unloadMovieNum(5); }
Perfect, works a treat! it takes me back to the next scene in the parent .swf, one last thing, sorry, is there a way to have it take me back to a scene and frame of my choice? Your help is massively appreciated!
You can use (replace the frame_number_here with the frame number): _level0.gotoAndPlay(frame_number_here); for scenes I'm not so sure... I don't use them sorry. Perhaps it might work : _level0.gotoAndPlay("scene_name_here",frame_number_here);
Thank you so much GWD! great help!! i was able to use the gotoandplay script to send it to a labelled frame in a different scene, didn't need to use the scene name!! Thanks again!
Don't see what you're looking for? Try a search.
|