I don't see any code, but in general, if the SWF you loaded does not
clean up after itself, there's no way to force it to unload.  You'll
need to find a way to stop the video and audio before loading something
else.

 

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Ben Reed
Sent: Friday, June 06, 2008 11:31 AM
To: [email protected]
Subject: [flexcoders] Flex Unload SWFLoader issues

 

Hi guys,

I have just today signed up with this mailing list after stumbling
across an issue I cannot resolve! Seems to be a flaw with the SWFLoader
in Flex 3. Basically my problem is this, I have to create a youtube
player for a client and am using the wrapper classes from martin legris
to aid me. All is working ok, I have a datagrid being populated by an
array, and when a video is selected, the SWFLoader loads it into place
as it should. The problem comes when selecting another video from the
list, several things happen (or dont!), the loaded Youtube player
disappears as if another one will be loaded into its place (the desired
effect) but nothing is loaded, also the sound from the original swf is
still audible.

Any suggestions or modifications to the code below would be most
welcome. I have read that possibly using Loader as oppose to SWFLoader
could be the way to go, or maybe Module Loader? I am ver new to flex but
not to actionscript and I seem to recall a similar problem once before
but I am damned if I can remember how (or if) i resolved it.

Anyway, I hope this hasn't been answered ages ago and if it has please
accept my apologies. I hope I can be of some use to some of you in
future postings! 

Cheers
--------------------------------
Ben Reed

 

Reply via email to