3 Replies Latest reply on Jul 2, 2010 9:20 AM by AttaBoy2

    FLV Player disappear after play


      Please help somewhat of an actionscript nimrod make an flv player disappear after its .flv has finished playing.  If someone could literally give me a cut/paste, you'd be savin' me.  Thanks in advance....

        • 1. Re: FLV Player disappear after play
          AttaBoy2 Level 4

          first go to window in the main menu

          then open components

          then drag a FLVPlayback component onto the stage.

          then delete the component from the stage(it will still be in the library where we want it)


          on frame 1 of the main timeline enter this code


          import fl.video.*;
          var vidPlayer:FLVPlayback = new FLVPlayback();
          vidPlayer.source = "gargons.flv";
          vidPlayer.addEventListener(VideoEvent.COMPLETE, remove);
          function remove(e:VideoEvent):void {
              vidPlayer.removeEventListener(VideoEvent.COMPLETE, remove);


          it works I just wrote and tested it

          I'll attach the project

          • 2. Re: FLV Player disappear after play

            Hey there,


            Just found this after hours of google-fu!


            I can't quite get it to work in Flash CS3 and I can't open your example zip files in Flash to see what I could tinker with there - think it's a version problem, seems common.


            I have my flv file. That's about as far as I can get! I tried renaming my video to suit your current files but my video's a different size (640*360) and then while the video disappeared the stage didn't...


            Would you mind terribly filling in the basic steps for a real n00b?! Do I need to export a SWF with / without my video file being in it first then publish the fla and html?

            • 3. Re: FLV Player disappear after play
              AttaBoy2 Level 4

              I downloaded the zip somehow the swf no longer worked but the fla did so I saved it in CS3 format, published and rezipped.  Now I can't find a way to upload I guess that's no longer allowed here.  As far a sizing goes you can always change your stage in the properties panel, you can make the video match the size of the stage vid.width = stage.stageWidth and vid.height = stage.stageHeight but as far as making the stage disappear from your html

              that's something maybe you could acomplish using external interface and javascript.  I don't know enough about the code there to do that.  If you load the swf into another swf then the stage would be invisible all you would see is the video which would diasppear when done.