On Fri, 8 Sep 2006 21:36:51 +0000 (UTC), "Mister Peanut"
[quoted text, click to view] <webforumsuser@macromedia.com> wrote:
>:confused;
>
> I have no idea why this isn't working... I've tried attaching this code to a
>button, to the actions layer, and to a frame... nothing happens!!
>
> on (release) {
> gotoAndPlay("Home", 1);
> }
>
> I've also tried using this code on all of them, too:
>
> home.onRelease = function (){
> gotoAndPlay ("Home", 1);
> }
>
> I want this button to link the user back to the scene "Home" in frame 1. For
>the life of me, I can't figure out why it isn't working.
>
> Any suggestions would be greatly appreciated....
Heres what works for me;
On the "Home" scene I have a button to go to WhatsUp page with the
following AS.
WhatsUpButton.onRelease = function() {
gotoAndPlay("WhatsUp", "WhatsUp");
//comment
gotoAndPlay("Scene", "Frame/FrameLabel");
//comment
}
First frame of scene "WhatsUp" has a frame label called "WhatsUp." I
am using this method to navigate across many scenes with no problems.
Using frame numbers is what will give you the problems, since frame 1
of the home scene may in fact not be frame 1 of the entire movie once
its exported. Use frame labels.
Read this:
http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_15703 Note: I am in the middle of my first flash project in over 5 years.
Lots has changed from 4 to 8 plus I never knew AS worth a damn anyway
so this IS NOT gospel, but I'm making it work...
"If you love wealth more than liberty, the
tranquillity of servitude better than the
animating contest of freedom, depart from us in
peace. We ask not your counsel or your arms.
Crouch down and lick the hand that feeds you.
May your chains rest lightly upon you and may
posterity forget that you were our countrymen."