Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

close flash movie using button

Status
Not open for further replies.

ailyngatmaitan

Programmer
Jan 24, 2007
1
PH
i'm doing my project which is a multimedia presentation and i'm using buttons for navigations like home, next, back. i would like to ask, what is the actionscript for an exit button that will close the flash movie
 
If for online use, I suggest you not close the user's browser window (I really hate that...), but simply unload the movie...

Code:
on(release){
    unloadMovieNum(0);
}

//Or...

exit_btn.onRelease = function(){
    unloadMovieNum(0);
}

If just a local projector file (or a local .swf player), the following would also work...

Code:
on(release){
    fscommand("quit");
}

//Or...

exit_btn.onRelease = function(){
    fscommand("quit");
}

Regards. Web Hosting - Web Design
03/13/05 -> OLDNEWBIE VS FLASHKIT
 

Helllo
I have a flash web site where, when a button(from the menu) is clicked a movieclip pop up on a different window...inside this file ther's also a menu and in here I have a button that SHOULD close the pop up window..I tried different codes but nothing seam to work THE POP UP WINDOW DO NOT CLOSE.
I tried these codes posted on this forum but none of them work,

CODE
on(release){
fscommand("quit");
}

//Or...

exit_btn.onRelease = function(){
fscommand("quit");
}

on(release){
unloadMovieNum(0);
}

//Or...

exit_btn.onRelease = function(){
unloadMovieNum(0);
}


the code
on(release){
unloadMovieNum(0);
}
makes the window white but the window it self do not close..
Does anyone have some suggestions..
Thanks.
Paola
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top