Media.bytesLoaded

Applies to

MediaDisplay, MediaPlayback.

Availability

Flash Player 7.

Edition

Flash MX Professional 2004.

Usage

myMedia.bytesLoaded

Description

Read-only property; the number of bytes already loaded into the component that are available for playing. The default value is undefined.

Example

The following code creates a variable called PlaybackLoad that is set with the number of bytes loaded. The variable is then used in a for loop.

// Create variable that holds the number of bytes that are loaded.
var PlaybackLoad:Number = myMedia.bytesLoaded;
// Perform some function until playback is ready.
for (PlaybackLoad < 150) {
    someFunction();
}

Flash CS3