dimensionav
asked on
How to unload a movie ?
HI
I am loading a movie over a container like this:
function containYoutube(youtubevar, depthLevel) {
this.createEmptyMovieClip( "youtubeco ntainer",d epthLevel) ;
this.youtubecontainer.load Movie("http://www.youtube.com/v/"+y outubevar) ;
}
but different videos are loaded at the same time in the same container, so I believe I should perform an instruction that could delete the instance created by createEmptyMovieClip in the previous event.
How to do that ?
Thanks
I am loading a movie over a container like this:
function containYoutube(youtubevar,
this.createEmptyMovieClip(
this.youtubecontainer.load
}
but different videos are loaded at the same time in the same container, so I believe I should perform an instruction that could delete the instance created by createEmptyMovieClip in the previous event.
How to do that ?
Thanks
ASKER
I have on release event the following:
on (release)
{
Security.allowDomain('http://www.youtube.com');
Security.allowDomain('http://gdata.youtube.com');
Security.allowInsecureDoma in('http://gdata.youtube.com');
Security.allowInsecureDoma in('http://www.youtube.com');
function containYoutube(youtubevar, depthLevel) {
removeMovieClip(mcDestino) ;
mcDestino.createEmptyMovie Clip("yout ubecontain er",depthL evel);
mcDestino.youtubecontainer .loadMovie ("http://www.youtube.com/v/"+youtub evar);
}
containYoutube("my string of URL video", mcDestino.getNextHighestDe pth());
}
After clicking in different buttons the previous video is still loaded and it plays at the same time of new ones.
on (release)
{
Security.allowDomain('http://www.youtube.com');
Security.allowDomain('http://gdata.youtube.com');
Security.allowInsecureDoma
Security.allowInsecureDoma
function containYoutube(youtubevar,
removeMovieClip(mcDestino)
mcDestino.createEmptyMovie
mcDestino.youtubecontainer
}
containYoutube("my string of URL video", mcDestino.getNextHighestDe
}
After clicking in different buttons the previous video is still loaded and it plays at the same time of new ones.
ASKER
The buttons and the video container are in the same level (inside other movieclips)
That's odd, how about
removeMovieClip(mcDestino. youtubecon tainer);
unloadMovie(mcDestino.yout ubecontain er);
If this doesn't work, can you upload your fla so I can take a look at it?
Good luck.
-V
removeMovieClip(mcDestino.
unloadMovie(mcDestino.yout
If this doesn't work, can you upload your fla so I can take a look at it?
Good luck.
-V
ASKER
The file has confidential content, could I send it to you by email?
Sure thing, you can look it up on my profile.
-V
-V
ASKER
Sent
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
removeMovieClip(this.youtu
That should work.
Good luck,
-V