Vlad
Vlad

Reputation: 2773

How to detect that streaming stopped AS3?

I have a flash app and I need to detect whether the streaming of data has stopped.

That means the connecton is still opened but the stream of data is cut of i.e no data in the pipe.

So I am asking which of these NetStatus events coresponds to this case?

NetStatus events from here http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/events/NetStatusEvent.html

I have used the "NetStream.Play.Complete" event but it doesnt work i.e doesnt detect this event

Upvotes: 0

Views: 1113

Answers (1)

mirrormx
mirrormx

Reputation: 4047

There is no "NetStream.Play.Complete" status (see your own link). Recently I've been working on a video player (which is based on NetStream class, too) and had a problem with identifing the video playback COMPLETE event. What seems to be working well for me is the "NetStream.Play.Stop" event. It doesn't get fired when you explicitly stop the streaming, but at the end of playback - at least for the video streaming, so it might be useful for you, too.

Upvotes: 2

Related Questions