Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 06-09-2005, 04:39 PM   #1
aldred
Registered User
 
Join Date: Mar 2005
Posts: 36
Default can't unload MediaDisplay in loaded swf

Hi

I have a slideshow using screens being cued by an flv (audio only) loaded using a MediaDisplay component.

This slideshow swf is loaded on a button release into a container movie using ....
ActionScript Code:
_parent.content_mc.createEmptyMovieClip("slideshow", 10); _parent.content_mc.slideshow.loadMovie("swf/slideshow.swf");
I then have another button to remove the created movie ....
ActionScript Code:
removeMovieClip(_parent.content_mc.slideshow);

This removes the screen slideshow visuals, but the flv narration continues to play. Why is this? I would have expected that it would be removed along with the swf that contained it. Also, if I try to just stop the audio then play again when I restart the slideshow, this doesn't work.

So my question is .... how can I stop the flv playing when I remove it's parent movie (ie *completely* unload slideshow.swf) so that slideshow.swf is initialised and ready to be loaded again? Or supposing I keep the slideshow in memory and just make it invisible, how would I reset it in this case?

thanks
mark
aldred is offline   Reply With Quote
Old 06-10-2005, 06:44 AM   #2
aldred
Registered User
 
Join Date: Mar 2005
Posts: 36
Default

Got it. In case anybody else is looking, adding this to the screens slideshow did the trick ....
ActionScript Code:
this.onUnload = function () { narration.setMedia("", "FLV"); };
mark
aldred is offline   Reply With Quote
Old 11-09-2005, 12:58 PM   #3
dcullinane
Registered User
 
Join Date: Jun 2004
Posts: 12
Default

can you explain this further? i am having the same issue
dcullinane is offline   Reply With Quote
Old 11-10-2005, 06:26 AM   #4
aldred
Registered User
 
Join Date: Mar 2005
Posts: 36
Default

I just added the onUnload code to I think it was the first frame of the swf containing the slideshow. When the slideshow is unloaded, narration.setMedia("", "FLV"); sends an empty reference to the audio flv and at the same time empties it of the previous audio flv.

mark
aldred is offline   Reply With Quote
Old 11-11-2005, 08:47 AM   #5
dcullinane
Registered User
 
Join Date: Jun 2004
Posts: 12
Default

I had figured it out already.

Thanks.
dcullinane is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:14 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.