# Flv play button wont work and im UPSET

**URL:** <https://forum.kirupa.com/t/flv-play-button-wont-work-and-im-upset/233106>\
**Category:** Uncategorized\
**Created:** [July 20, 2007, 3:57am UTC](https://forum.kirupa.com/t/flv-play-button-wont-work-and-im-upset/233106 "2007-07-20T03:57:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![aeroshock](https://avatars.discourse-cdn.com/v4/letter/a/8797f3/32.png) [@aeroshock](https://forum.kirupa.com/u/aeroshock)\
**Post date:** [July 20, 2007, 3:57am UTC](https://forum.kirupa.com/t/flv-play-button-wont-work-and-im-upset/233106/1 "2007-07-20T03:57:17Z")

</div>

I am begging for help, ive been at this for days. I cant for the life of me figure out how to get my flv pause button to work. I have a movie clip on the stage called scott\_mc. inside is another clip called loader\_mc which is masked (the flv attaches to loader\_mc). so the video is masked.

anyway i want to be able to click the scott\_mc on stage and have it pause/unpause. Please tell me the error of my ways.

```auto

package
{
        import flash.media.*;
        import flash.utils.*;
        import flash.display.*;
        import flash.events.*;
        import flash.net.*;
        import fl.video.*;
        import fl.containers.UILoader;
        
        public class Scott extends MovieClip
        {
                
                public function Scott()
                {
                        var videoConnection:NetConnection = new NetConnection();
                        videoConnection.connect(null);
                        var videoStream:NetStream = new NetStream(videoConnection);
                        videoStream.play("scott1.flv");
                        var metaListener:Object = new Object();
                        metaListener.onMetaData = onMetaData;
                        videoStream.client = metaListener;
                        var video1:Video = new Video();
                        video1.attachNetStream(videoStream);
                        loader_mc.addChild(video1);
                        
                        
                        video1.width = 162;
                        video1.height = 208;
                        video1.x = 0;
                        video1.y = 0;
                        videoStream.seek(.1);
                        videoStream.togglePause();
                        
                        function onMetaData (data:Object):void
                        {
                                scott_mc.addEventListener(MouseEvent.CLICK, playMovie);
                        }
                        
                        function playMovie (event:MouseEvent):void
                        {
                                videoStream.togglePause();
                        }
                        
                        //video size 162 X 208
                        
                        
                }
                
        }
}

```
