4 Replies Latest reply on Apr 26, 2010 12:53 PM by robva65

    Navigation Control




      I need to use a Flash file I created to be for Adobe Presenter. The scenario is like this: The user is on Slide 1 and must interact with the Flash piece. The next button to advance them to the next slide is disabled until they complete the Flash exercise.


      So how would I use action script to control the navigation of a Presenter File?



        • 1. Re: Navigation Control
          robva65 Level 2



          One method you could explore is using some Actionscript in your Flash piece that would be set up to control Presenter's elements in the playback bar.


          The specific code you'd use may vary, but one option might include using an onEnterFrame event handler.


          In Flash, make sure you have a separate layer for actions. Then add the following to the first frame in your actions layer:


          this.onEnterFrame = function () {

          _root.m_controlBar.m_slideNextBtn.enabled = false;



          Now depending on how you have your Flash file set up, you could re-enable the Next button based on conditions....so for example, one scenario might be if the playhead of your anim reaches a certain frame, then simply envoke the m_slideNextBtn object and reset it to "true".  Another example might include an "if" conditional, such that if a certain scenario is true, then reset the Next button's status.




          if (condition){

               _root.m_controlBar.m_slideNextBtn.enabled = true;



          Without knowing what you've set up your Flash file to do, it's a bit hard to suggest how to handle this with 100% certainty...but hopefully this will put you on a path so that you can work it out.





          • 2. Re: Navigation Control
            macrocream Level 1

            I went through your suggestion and applied it. Interestingly I have some difficulty as by publishing this from presenter, the AS is not honored by the Presenter viewer.


            Frame one (AS)


            this.onEnterFrame = function() {
                  _root.m_controlBar.m_slideNextBtn.enabled = false;
            btnName.onRelease = function() {
                  _root.m_controlBar.m_slideNextBtn.enabled = false; //set this to false as well to just see if I could get it to disable


            I publish the swf and import to presenter, then publish a two slide presenter presentation. In the presenter viewer the next button in the lower nav bar is not getting disabled. Any ideas?



            • 3. Re: Navigation Control
              macrocream Level 1

              Found the problem, you must publish to Flash Player 6.

              • 4. Re: Navigation Control
                robva65 Level 2

                Hey Macro,


                Yeah, sorry about that....I forgot to mention that it is required that you publish the Flash file using Actionscript 2.0.  You could have published to version 6, 7, or 8 and that would have worked SO LONG AS the version of Actionscript is set to 2.0.


                Glad that's working for you!