BUG: ActiveMovie Mixing Sample (AM.htm) Not Working CorrectlyLast reviewed: February 27, 1998Article ID: Q181778 |
The information in this article applies to:
SYMPTOMSThe buttons in the ActiveMovie Mixing sample that is included with the Internet Client SDK (\INetSDK\Samples\DHTML\MMAudio\AM.htm) never become enabled. Also, on Windows NT, no mixing occurs. Only one sound plays at a time.
CAUSEThe first problem is the result of script errors in the HTML page. This sample incorrectly defines the ReadyStateChange event handler as taking no parameters. In fact, ReadyStateChange takes one parameter, and therefore the script handlers never catch the event. The second problem is by design. The ActiveMovie control does not support mixing on Windows NT.
RESOLUTIONChange the event handler definitions for ReadyStateChange in the <SCRIPT> block to the following:
Sub AM?_ReadyStateChange(ReadyState)NOTE: The ? (question mark sign) is both 1 and 2. Also, on the AM2 object tag declaration, change the FileName PARAM to read:
<PARAM NAME="FileName" VALUE="drums.wav">To support mixing on Windows NT, the Direct Animation control must be used in lieu of the ActiveMovie control. The AudioMixing DirectXMedia sample (\INetSDK\Samples\DXM\Samples\da\VBScript\Templates\AudioMixing.html) has a good demonstration of mixing equivalent to AM.htm.
STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this bug and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONThe ActiveMovie mixing sample demonstrates sound mixing using the ActiveMovie Control. This sample contains two buttons, one for channel A and one for channel B. Each channel has an associated sound that can eventually be played by pressing one of these buttons. The text color of these buttons is initially set to white to indicate that the channels are being loaded. In addition, two variables (achan and bchan) are declared and initially set to the value of 2 to indicate that the channels are being loaded. When the each channel is finished loading, the ActiveMovie control fires the ReadyStateChange event. The event handlers for this event set achan and bchan to 0 to indicate that the sound associated with each channel is ready to be played. Because this sample declares the event handlers for ReadyStateChange incorrectly, the buttons are never enabled, and therefore pressing these buttons has no effect. Also note that the second ActiveMovie control has been given an incorrect file name for its sound file.
|
Additional query words: ActiveMovie am.htm
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |