Lingo Dictionary > S > streamSize

 

streamSize

Syntax

member(whichFlashMember).streamSize
the streamSize of member whichFlashMember

Description

Cast member property; reports an integer value indicating the total number of bytes in the stream for the specified cast member. The streamSize property returns a value only when the Director movie is playing.

This property can be tested but not set.

Example

This frame script checks to see if a Flash movie cast member named Intro Movie has finished streaming into memory. If it hasn't, the script updates a field cast member to indicate the number of bytes that have been streamed (using the bytesStreamed member property) and the total number of bytes for the cast member (using the streamSize member property). The script keeps the playback head looping in the current frame until the movie finishes loading into memory.

on exitFrame 
	if member("Intro Movie").percentStreamed < 100 then
		member("Message Line").text = string(member("Intro Movie").bytesStreamed) \
		&& "of" && string(member("Intro Movie").streamSize) \
		&&"bytes have downloaded so far."
		go to the frame
	end if
end