Microsoft KB Archive/178707

= PRB: Unable to Play .wav file from Applet or AudioClip =

Article ID: 178707

Article Last Modified on 6/14/2006

-

APPLIES TO


 * Microsoft Visual J++ 1.0 Standard Edition
 * Microsoft Visual J++ 1.1 Standard Edition
 * Microsoft Software Development Kit for Java 1.51
 * Microsoft Software Development Kit for Java 2.02
 * Microsoft Software Development Kit for Java 2.01
 * Microsoft Software Development Kit for Java 2.02
 * Microsoft Software Development Kit for Java 3.0
 * Microsoft Software Development Kit for Java 3.1
 * Microsoft Software Development Kit for Java 3.2

-



This article was previously published under Q178707



SYMPTOMS
When an Applet tries to play a .wav file from an applet using the Applet.play method or the AudioClip.play method, either nothing happens or you get the following console output: NativeAudioStream: invalid file type



CAUSE
The Sun Microsystems Inc. Java Development Kit (JDK) 1.02 and 1.1 APIs are able to play only AU files. The AU files need to be 8 bit, ulaw, 8000 Hz, and one channel.



RESOLUTION
Use a product that is capable of creating AU files according to these specifications. Convert the .wav file and change the URL to point to the AU file.



STATUS
This behavior is by design.

