Stream.onStatus

Availability

Flash Communication Server MX 1.0.

Usage

myStream.onStatus = function([infoObject]) {}

Parameters

infoObject An optional parameter that is defined according to the status message. For more information about this parameter, see Server-Side Information Objects.

Returns

Nothing.

Description

Event handler; invoked every time the status of a Stream object changes. For example, if you play a file in a stream, Stream.onStatus is invoked. Use Stream.onStatus to check when play starts and ends, when recording starts, and so on.

Example

The following example defines a function that executes whenever the Stream.onStatus event is invoked:

s = Stream.get("foo");
s.onStatus = function(info){
        // Insert code here.
};