4 Replies Latest reply on Jul 9, 2008 6:46 AM by DemonGFish

    script not completing

    DemonGFish
      i have a button that runs a series of depthswaps and also causes several movies to change frame. i wont go into detail.

      the problem is that about half way through these actions the movie the button is contained within changes fram, which removes this button. as a result the script is not completed after this point.

      i can't change the order of the code, so is there anything that can tell it to run the script all the way thru even if the frame changes?

      did that make sense?
        • 1. Re: script not completing
          robdillon Most Valuable Participant
          Write the function in a frame action space and call the function from the button action.
          • 2. Re: script not completing
            DemonGFish Level 1
            hmm not really an option, it's given me an idea though that might work.

            the thing is it is a set of buttons within a movie, that movie will be used in various places around the main movie [i'm not too familiar with proper lingo here]

            is there not a way to say 'read this list of things to do but dont start untill you have read them all' so to speak.
            • 3. Re: script not completing
              clbeech Level 3
              Rob's right - create a method in the main timeline that contains all of the items to do, then call that method from any of your buttons - write it dynamically so that it will work from an instance, and pass parameters to the method if needed. in this way the method will 'always' exist even if the movies change frames or the buttons 'move' or swap depths. in this way it doesn't matter what happens to any of the items on stage, the method will always run to completion.
              • 4. Re: script not completing
                DemonGFish Level 1
                ok that sounds like it might work.

                thanks guys!

                quick question. in another thread i asked about importing RSS feeds, i've noticed when this has been asked in other forums it's largely ignored. is it a stupid question or just way too hard to answer?