A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: when netstream start I want an object to be removed from the stage

  1. #1
    Junior Member
    Join Date
    Sep 2005
    Posts
    16

    when netstream start I want an object to be removed from the stage

    Ok, I have been looking everywhere for this...so I have now decided to post to see if someone can help me.

    I have two FLV files playing on the stage. The main FLV is instance is: MyVideo

    the 2nd is MyVideo2

    I have imported the videos using the wizard. The 2nd video is just a movie I created in Affter Effects that says...loading please wait....this is a really nice video and I don't want it to just use a standard preloader. Anyway, the goal is when the playback for "MyVideo" begins I would like "Myvideo2" to = visible = false;

    I have tried this many different ways and have been unsuccessful. I am obviously a newb at this. Also, does anyone know where I can get a list of all available eventListener actions...etc? One of my problems is that I don't even know what commands are available and what they can do. Thanks!
    ----Code is commented because I could not get it to work. -----

    //var nc:NetConnection = new NetConnection();
    //connection_nc.connect();
    //var stream_ns:NetStream = new NetStream(connection_nc);
    //my_video.attachVideo(stream_ns);
    //var duration:Number = 0;
    //var ratio:Number = 0;
    //var id:Number = 0;
    //
    //
    //nc.connect(null);
    //
    //
    //
    //myNetStream = new NetStream(nc);
    //
    //myVideo.attachVideo(myNetStream);
    //
    //
    //myNetStream.play("CustomerStateOfMindPart2.flv");
    //
    //myNetStream.pause();
    //
    //myNetStream.onStatus = function(info)
    //
    //{
    //
    // if (info.code == "NetStream.Play.Start")
    //
    // {
    //
    // MyVideo2._visible = false;
    //
    // }
    //
    //};

  2. #2
    Member
    Join Date
    Aug 2010
    Posts
    65
    for a list of event listeners : http://help.adobe.com/en_US/FlashPla...ge-detail.html

    in the same page you will find plenty of functions and descriptions of what they can do. For as2 there is http://help.adobe.com/en_US/AS2LCR/F...LangRef_1.html

    also you can use
    Actionscript Code:
    /*
    multi
    line
    comments
    */
    so that you wouldnt have to add backslashes to every line

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center