9 Replies Latest reply on Jun 26, 2006 7:56 AM by kglad

    help with menu button and movie load

      Hello everyone....I am very new to flash and actionscripting and am self taught using mostly web research.
      I am building a site with a menu and a banner that is controlled by the menu (two swf files). I have managed to get them to communicate however, I am stuck at this point.
      When "bt_1" is hit I would like a "mv_1" to load in the banner.swf with is respected intro animation...this I figured out how to do...however now when "bt_2" is clicked I would like play the remainder of the animation of "mv_1" to unload the movie before "mv_2" loads with its respected enterance animation....this I would like to do for several buttons. The method I am using for my local connection is this....

      Sending script
      mySender = new LocalConnection();
      on (release) {
      \\ each button has a different param...1,2,3,4,5,6
      _root.mySender.send("menuconnect", "action", 1);
      \\ this is the best way I could figure out to disable the appropriate buttons..there might be a better way??
      home.enabled = false;
      couple.enabled = true;
      events.enabled = true;
      bridal.enabled = true;
      media.enabled = true;
      rsvp.enabled = true;

      Recieving script

      myReceiver = new LocalConnection();
      myReceiver.action = function(doThis) {
      if (doThis == 1)
      if (doThis == 2)
      //and so and soforth for all six buttons

      If all this makes no sense I'm sorry...I tried my best...
      If some pro out there can understand what I'm trying to do and can help me I would greatly appreciate it....thank-you all

        • 1. Re: help with menu button and movie load
          kglad Adobe Community Professional & MVP
          i'd use linkage ids to bring each of your mv_1, mv_2 etc to the main stage and control them. this would have the benefit of eliminating duplicate code and keeping most of your code in one location (frame 1 of your _root timeline).

          if mc_1 etc had linkage id mc_1ID etc, the outros began on a frame labeled "outro" and ended on the last frame, you could use:

          • 2. Re: help with menu button and movie load
            kglad....thanks a bunch for you quick reply and I'm sure that it will work only problem is I have no idea what is going on in your code...
            I will keep trying to use your example and apply it to my movie but if there is anyway you could explain what is going on, that would be awesome.
            Once again my ignorance may be a lack of basic programing skills and if I'll be glad to learn if you could point to a source
            • 3. Re: help with menu button and movie load
              kglad Adobe Community Professional & MVP
              same code as above with comments:

              1 person found this helpful
              • 4. Re: help with menu button and movie load
                kglad...thanks again, that cleared up a lot....I'm at work and as soon as I can get home I am going to experiment with this. The next thing I need to get working is learing how to use linkage...I've read a little about it and hope to be able to figure it out....any suggestions will be appreciated I will post my results...thanks again for your time and trouble.
                • 5. Re: help with menu button and movie load
                  KGlad...I'm stuck again....:-(. I guess I'm not understanding this linkage thing well enought...
                  if you don't mind tell me what you had in mind when you helped me with that code...this is my situation again....
                  here is the actual website....www.beckyandsangeeth.com
                  the menu on the left of course has the buttons and I want the animation pertaining to each button to load in the apparent banner region, (which I am still working on the indivual animations).
                  I guess I'm not understanding where the movies are loaded and how they are linked...and so and soforth...thanks again
                  Also I don't mean to be specifically speaking to kGlad...anyone out there I am open for ideas.

                  • 6. Re: help with menu button and movie load
                    kglad Adobe Community Professional & MVP
                    to set a linkage id for a movieclip right click on it in your library panel, click linkage, tick export for actionscript and fill in a linkage id ( the code i gave used mc_1ID, mc_2ID etc), click ok.
                    1 person found this helpful
                    • 7. help with menu button and movie load
                      kglad...I feel bad to keep asking you questions considering I feel like I don't have a good grasp as to how this whole thing works..
                      So if this is too much to explain I will understand. I feel that my setup of the movies pertaining to the frame setup and layer setup may be what is conflicting and I dont' know how to fix it...

                      here are my fla files...if you feel inclined to take a look at them...I would be grateful. I have learned a lot but obviously not enough to get this to work..I will also include the html file to that loads them.

                      My fla files
                      • 8. Re: help with menu button and movie load
                        kglad....I finally got it working!!!!!!!
                        I'm am pretty excited.....now that I got it I feel pretty stupid that it took me so many hours....but O well learned a lot..thanks again!!!
                        now onto my next challege....
                        • 9. Re: help with menu button and movie load
                          kglad Adobe Community Professional & MVP
                          you're welcome! good job.
                          1 person found this helpful