Skip to main content
Participant
February 17, 2007
Question

how to disable background movie

  • February 17, 2007
  • 3 replies
  • 408 views
I’m building a photo gallery in flash. I have a main movie(call it parent movie if you want) which has a collection of small thumbnails of photos. I click on the small thumbnails to enlarge the photos. It's actually loading(targetMC) a child movie contains the enlarged photo. The main movie(parent) will be screened back and disabled. There’re two buttons (previous and next) in the enlarged mode. So the user can still click forward or backward without going back to the parent movie. When the user clicks the enlarged photo itself, it closes the child movie and goes back to the active parent film. I used targetMC to do this, but I seriously doubt this is the right approach. It may not need child movies at all because if I have 100 photos on the main movie, I'll have to make 100 individual child movies: totally screwed. Can anyone give me an advice on how to build something like that?

Thanks a lot.
This topic has been closed for replies.

3 replies

kglad
Community Expert
Community Expert
February 18, 2007
try: assuming your movieclip was not created in the authoring environment using this.removeMovieClip() will work. otherwise, you need to use swapDepths() first to move your movieclip to a removable depth.

help for the enabled property is under the movieclip class and button class.
descenteAuthor
Participant
February 19, 2007
quote:

Originally posted by: kglad
try: assuming your movieclip was not created in the authoring environment using this.removeMovieClip() will work. otherwise, you need to use swapDepths() first to move your movieclip to a removable depth.

help for the enabled property is under the movieclip class and button class.


What you mean by "not created in the authoring enivonment"? The child movie is a swf file which contains the enlarged photo(I made it into a button, and tried to assign the unload function to it upon clicked).
kglad
Community Expert
Community Expert
February 18, 2007
you can use the enabled property of movieclips to enable/disable movieclips.
kglad
Community Expert
Community Expert
February 17, 2007
there's no issue using a child movieclip as that target of your enlarged pic loads except it might impact performance if you have hundreds of them. so, just create them during runtime when they are needed and use removeMovieClip() to unload the enlarged pic and remove the child movieclip.
descenteAuthor
Participant
February 18, 2007
but how do I disable the parent movie when the child movie is loaded? thanks.