hasAudio Property
This topic documents a feature of HTML+TIME 2.0, which is obsolete as of Windows Internet Explorer 9.
Gets a Boolean value that indicates whether the media contains audio.
Syntax
HTML N/A Scripting [ bAudio = ] object.hasAudio
Possible Values
bAudio Boolean that receives one of the following values.
- false
- Default. The media does not contain audio.
true
- The media has audio.
The property is read-only. The property has a default value of false.
Remarks
The hasAudio property returns
true
if the media has audio, regardless of the mute setting or the volume setting.
Example
The following code example uses an alert message to show the value of the hasAudio property.
<HTML XMLNS:t="urn:schemas-microsoft-com:time"> <HEAD> <TITLE>hasAudio Property</TITLE> <?IMPORT namespace="t" implementation="#default#time2"> <STYLE> .time{ behavior: url(#default#time2);} </STYLE> <SCRIPT> function doFunction(){ alert('hasAudio: ' + m1.hasAudio); } </SCRIPT> </HEAD> <BODY TOPMARGIN=0 LEFTMARGIN=0 BGPROPERTIES="FIXED" BGCOLOR="#FFFFFF" LINK="#000000" VLINK="#808080" ALINK="#000000"> <t:media id="m1" begin="0" src="/workshop/samples/author/behaviors/media/shuttle3.wmv" onmediacomplete="doFunction();" fill="remove"/> </BODY> </HTML>
Applies To
t:ANIMATION, t:AUDIO, t:IMG, t:MEDIA, t:REF, t:VIDEO
See Also