Event Listeners

I know other people are having the same trouble with this and I’ve found a few threads that seem to solve the problem, but I’m not having any luck with it. I would like to detect the end of an .flv so I can add actions afterwards. Maybe someone here can help me out?

var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
ns.setBufferTime(5);
myVideo.attachVideo(ns);
path = "videos/";
ns.play(path+"test.flv");
var listenerObject:Object = new Object();
// listen for complete event
listenerObject.complete = function(eventObject:Object):Void  {
    trace("flv complete....");
};
myVideo.addEventListener("complete", listenerObject);