A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: How to make a button go to another swf and frame?

  1. #1
    Senior Member gkbdave's Avatar
    Join Date
    Nov 2000
    Location
    Fort Bragg, NC
    Posts
    304

    How to make a button go to another swf and frame?

    I am having a hard time figuring out how to have a button load a swf file and on a certain frame of that swf.

    Can this even be done?? I can get the swf to load fine but its getting to the specific frame that stuck on.

    Can anyone help?

    Thanks in advance..

  2. #2
    Senior Member MagnusVS's Avatar
    Join Date
    May 2005
    Location
    Oslo, Norway
    Posts
    764
    why not just load the movie and put a goto -action in the loaded mc?

  3. #3
    Senior Member gkbdave's Avatar
    Join Date
    Nov 2000
    Location
    Fort Bragg, NC
    Posts
    304
    The reason I don't do that is because I want to reuse a certain frame in that .swf. Instead of rebuildign it again.

    thanks

  4. #4
    Senior Member gkbdave's Avatar
    Join Date
    Nov 2000
    Location
    Fort Bragg, NC
    Posts
    304
    Ok,
    I have tried to put a gotoandPlay(4) after the loadmovie action. It loaded the movie fine, but didnt' go to the certain frame.

    There has to be a way to do this.

  5. #5
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    You can set a variable ( with the frame label name to go to ) with the button and have a action in the external swf read and act upon it.... like...

    // Example loading a swf into a movieclip called container
    on(release){
    _root.whereToGo="gallery";
    container.loadMovie("movie2.swf");
    }

    On the fiorst frame of movie2.swf ...

    if(_root.whereToGo!=undefined){
    this.gotoAndPlay(_root.whereToGo);
    }

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center