Client-Side Communication ActionScript > Microphone.muted

 

Microphone.muted

Availability

Flash Player 6.

Flash Communication Server MX (not required).

Usage

activeMicrophone.muted

Description

Read-only property; a Boolean value that specifies whether the user has denied access to the microphone (true) or allowed access (false). When this value changes, Microphone.onStatus is invoked. For more information, see Microphone.get.

Example

In the following example, when the user clicks the button, Flash publishes and plays a live stream if the microphone is not muted.

on (press) 
{
	// If the user mutes microphone, display offline notice.
	// Else, publish and play live stream from microphone.
	if(myMic.muted) {
		_root.debugWindow+="Microphone offline." + newline;
	} else {

		// Publish the microphone data by calling
		// the root function pubLive().
		_root.pubLive();
	
		// Play what is being published by calling
		// the root function playLive().
		_root.playLive();
	}
}

See also

Microphone.get, Microphone.onStatus