Sound.getBytesTotal( ) Method | Flash 6 |
the physical disk size of an external sound file, in bytes |
An integer representing the size of the sound file, in bytes. Divide by 1024 to convert bytes to kilobytes (KB).
The getBytesTotal( ) method tells us the byte size of an external file being loaded into soundObject via loadSound( ). For a new Sound object, getBytesTotal( ) returns undefined. Immediately after each call to loadSound( ), getBytesTotal( ) also returns undefined until the size of the sound file being loaded is determined. After that, it returns the total byte size of the loading sound until the next call to loadSound( ).
For Sound objects, getBytesTotal( ) is used together with getBytesLoaded( ) to determine (and display, normally) the load progress of a downloading sound file. See Sound.getBytesLoaded( ) for details and example code.
Sound.getBytesLoaded( ), Sound.onLoad( )