I restarted my computer twice now it seems to work fine...

Robin

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Robin
Burrer
Sent: Wednesday, 18 April 2007 12:47 PM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] ArgumentError: Error #2126: NetConnection object
mustbe connected - this is killing me


Hi there,

I want to build a flv player in AS3. 

However once I try the net connection object Flex Builder decides to
screw up my entire project and refuses to compile it again regardless
what I do.

Even if I delete all the code in my base class Flex builder still gives
me that error message:

ArgumentError: Error #2126: NetConnection object must be connected.
        at flash.net::NetStream/flash.net:NetStream::construct()
        at flash.net::NetStream$iinit()
        at
VideoPlayer/VideoPlayer::initVideoConnnect()[E:\vss_data\HUBB\HUBB
Investor\videoPlayer2\VideoPlayer.as:54]
        at VideoPlayer$iinit()[E:\vss_data\HUBB\HUBB
Investor\videoPlayer2\VideoPlayer.as:35]

 
I physically have to delete my project and create it again to compile
it.

Any ideas?


Robin

// init video connection
                private function initVideoConnnect():void
                {
                        // create netStream 
                        
                        var myConnection:NetConnection  =  new
NetConnection();
                        
                        // these two lines kill my project 
                        myConnection.connect(null);
                        myStream = new NetStream(myConnection);
                        myStream.play("temp/video.flv");
                
                        // add listener
        
//myConnection.addEventListener(NetStatusEvent.NET_STATUS,onNetStaus);
                        
                
                
                        
                        
}



_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to