6 Replies Latest reply on Aug 14, 2006 10:37 PM by dawu

    loop a different flv after the first .flv ends

    dawu
      Can someone point me to a tutorial or page to make this idea work?

      I want to loop a different .flv after the movie player played the initial .flv file.

      Thanks
        • 1. Re: loop a different flv after the first .flv ends
          Level 7
          Kinda depends on your application such as are you using the FLVPlayer or
          writing Actionscript yourself. Where are the FLV URI's stored or gotten?

          If the FLVPlayer, just change the contentPath property
          http://livedocs.macromedia.com/flash/8/main/00003539.html.
          my_FLVPlybk.contentPath = streamURI;

          If AS
          my_ns.close();
          my_ns.play(streamURI);

          In either case you could keep the FLV URIs in an array or get them from a
          ComboBox or other possible design choices.

          --
          Lon Hosford
          www.lonhosford.com
          May many happy bits flow your way!
          "gwu630" <webforumsuser@macromedia.com> wrote in message
          news:e30u9q$er1$1@forums.macromedia.com...
          Can someone point me to a tutorial or page to make this idea work?

          I want to loop a different .flv after the movie player played the initial
          .flv file.

          Thanks


          • 2. Re: loop a different flv after the first .flv ends
            dawu Level 1
            Thanks Motion Maker.

            I am using the Flash 8 video player component that has a component panel which I can input one movie path url. How can it tell it to loop a second movie after the first one is done?

            Please advise.

            Thanks,
            gwu630
            • 3. Re: loop a different flv after the first .flv ends
              Level 7
              We are assuming "Flash 8 video player" means the FLVPlayback Flash 8
              component.

              You need to give the FLVPlayer instance a name in the properties window on
              stage. Ex below uses myFlvPlayer.

              Clear the contentPath parameter on stage in the properties window.

              Add this code to the timeline:

              var myPlayListIndex:Number = -1;
              var myPlayList:Array = new Array();


              // Add these lines for each flv file
              myPlayList.push("yourfirst.flv");
              myPlayList.push("yourSecond.flv");
              myPlayList.push("yourthird.flv");



              function playNextFlv()
              {
              trace("playNextFlv()");
              if (myPlayListIndex < myPlayList.length - 1)
              {

              myFlvPlayer.contentPath = myPlayList[++ myPlayListIndex];

              }
              }

              myFlvPlayerListener = new Object()
              myFlvPlayerListener.complete = function(evt)
              {
              trace("myFlvPlayerListener.complete - evt:" + evt.target);
              playNextFlv()
              }
              myFlvPlayer.addEventListener("complete", myFlvPlayerListener);
              playNextFlv();


              --
              Lon Hosford
              www.lonhosford.com
              May many happy bits flow your way!
              "gwu630" <webforumsuser@macromedia.com> wrote in message
              news:e34al8$hp5$1@forums.macromedia.com...
              Thanks Motion Maker.

              I am using the Flash 8 video player component that has a component panel
              which
              I can input one movie path url. How can it tell it to loop a second movie
              after
              the first one is done?

              Please advise.

              Thanks,
              gwu630


              • 4. Re: loop a different flv after the first .flv ends
                dawu Level 1
                Can someone show me how to loop a flv movie?
                • 5. Re: loop a different flv after the first .flv ends
                  Level 7
                  import mx.video.*;
                  var listenerObject bject = new Object();
                  listenerObject.complete = function(eventObject bject):Void
                  {
                  my_FLVPlybk.play();
                  };
                  my_FLVPlybk.addEventListener("complete", listenerObject);
                  my_FLVPlybk.contentPath =
                  " http://www.helpexamples.com/flash/video/water.flv";



                  --
                  Lon Hosford
                  www.lonhosford.com
                  May many happy bits flow your way!
                  "gwu630" <webforumsuser@macromedia.com> wrote in message
                  news:e3c5hj$r4u$1@forums.macromedia.com...
                  Can someone show me how to loop a flv movie?


                  • 6. Re: loop a different flv after the first .flv ends
                    dawu Level 1
                    How can I direct the swf to play the next frame on the timeframe after the flv ends?