all groups > flash actionscript > august 2004 >
You're in the

flash actionscript

group:

Getting reference to a movie at runtime



Getting reference to a movie at runtime samuel NO[at]SPAM 3hgroup.com
8/8/2004 7:03:02 PM
flash actionscript: Hi There

I am currently loading movies into various layers in a container swf
using the LoadMovie() function.

I then need to get access to a movie on a particular layer and change
variable values. I don't know what movie is currently on the layer and
need to access it at runtime.

How do I get a reference to the movie on a layer. I know the layer but
not the movie name. The movie should always be on the 1st frame.

Hope that makes sense.

Re: Getting reference to a movie at runtime Abhiuday
8/9/2004 9:21:05 AM
Hi,

Load the movies into different levels so that u can access the movies using
level number..u then dont need to know the names of the movie.

Eg: loadMovieNum('myMovie1',1)
loadMovieNum('myMovie2',2)

To access a movie reference it using : _level1 or _level2.(ur code here)

Abhi
AddThis Social Bookmark Button