Playing rtmp FLVs

Hello all, I have made a custom simple FLV player using a video symbol and the NetConnection and NetStream. The code I used is below.

var nc:NetConnection = new NetConnection();
nc.connect(null);


var ns:NetStream = new NetStream(nc);

theVideo.attachVideo(ns);

ns.play("300.flv");

My problem is the file that I want to play is on a Flash Media Server with the following type of URI rtmp://myserver.com/video/test.flv

The above code works perfectly but using a Flash Media Server it doesn’t.

How can I modify the script I have so it plays this new file? Just copying the URI to the media component of Flash plays it without any problems.

I would really apreciate your help here guys. Thanks.