R – flex NetStream.DIRECT_CONNECTIONS exists

apache-flexflexbuilder

i am trying to run a source that i downloaded in Flex Builder 3
but i get some errors:

like on this line:

sendStream = new NetStream(nc,NetStream.DIRECT_CONNECTIONS);

Access of possibly undefined property DIRECT_CONNECTIONS through a reference with static type Class.

and here

myPeerID = nc.nearID;

//nc is NetConnection
and code completion also doesn't show me the nearID property of the NetConnection

Best Answer

The problem is NetStream.DIRECT_CONNECTIONS s part of flex 4 and is not available in flex 3.

check:

http://livedocs.adobe.com/flex/gumbo/langref/flash/net/NetStream.html#DIRECT_CONNECTIONS

Related Topic