Lets cover some methods about loading movies, images, sounds or anything from outside flash into a parent SWF movie.
There are main two methods
- Loading By Level
- Loading By Target
Loading External Elements By Level
Levels are good to load movies or jpg or anything and they are called by numbers like level 1, level 2 etc. and in that level 1 will be always first level and 2 will be above from that and 3 will come above than 2. That means element residing at level 1 will be underneath element residing at level 2 in a movie.
Syntax is given here:
Loading External Elements By Target
In target a container movie clip is created in a movie. Container is a movie clip with its center left-top aligned. When u load a movie or jpg etc through target you point the target into that container.
Syntax is given here
mycontainer here is the name of targeted movieclip inwhich somecontent.swf will be placed from outside.
* In example you see, target container movieclip is of blue color. That does not matter. This movie clip will be transparent and will collect all the content of external movie and will display. It is just the targeting container, so its own real self will be hidden. It is necessary that you take target container of same width and height as the external container.
* Background of target movie clip or external movie clip in target case will be hidden and the main movie background will be visible in which target container is placed.
Target and level can be used both and you can also load external sounds by any of above methods.