If you have installed a previous version of the cgjsapi.jar and cgjsapi1xx.dll files, you will need to remove them, or overwrite them with the new ones - otherwise the old files might be located first by the Java class loader (if they are pointed to by the CLASSPATH variable) and used instead of the new ones.
Similarly, if you ran the "installAppletJars.bat" file from a previous version, then you will need to remove the "com/cloudgarden" and "javax/speech" folders and cgjsapi.jar file in the C:/Windows/Java/Classes directory, and the cgjsapi.dll file in the C:/Windows/System32 directory, since some of these locations might be included in your CLASSPATH variable and so any old class files in that folder might be found before any new ones.
It may be simplest just to search your system for any cgjsapi.jar and cgjsapi1xx.dll files, and remove them.
Also, make sure any other JSAPI installation (such as IBM's "ibmjs.jar" file) is uninstalled first (or at least removed from the CLASSPATH).
If, after installing using one of the methods below, your installation still doesn't seem to work, read the "What to try if it doesn't work" section.
JMF and the JavaSound standard extension
In order to use the com.cloudgarden.audio package, the Java Sound extension (in particular the javax.sound.sampled package) must be installed on your system. This comes as part of the JRE 1.3, but if you are not using Java 1.3, or wish to use JSAPI from an Applet in Internet Explorer or Netscape you will need to get the Java Media Framework 2.1.1, which contains the Java Sound implementation in the sound.jar and jsound.dll files. When you install the JMF check the "Use from Applets" option if you want to use it from applets. This installs (among other things) the sound.jar and jsound.dll in locations where Netscape and IE can read them. The Applets section describes the steps needed to allow the cgjsapi.jar and cgjsapi.dll files to be run from an applet - the same steps are carried out by the JMF installer.
In order to use the getDataSource and getDataSink methods of CGAudioManager the full JMF needs to be installed (since these methods integrate the JSAPI with the JMF).
To install manually, extract the files in the TalkingJavaSDK-1xx.jar or zip files to get two files: packet.jar and Setup.exe. Then unjar the packet.jar file to get the SDK files:
CLASSPATH and PATH notes
Alternatively you can edit the CLASSPATH line in the AUTOEXEC.BAT file to include the path to the cgjsapi.jar file (doesn't matter where you put it) and the PATH line to include the directory where the cgjsapi1xx.dll file is.
java examples.synthesis.SynthesizerTestshould get your machine speaking in English to you (though it might come out with a foreign accent!) - it should also print events to the console. If the initial tests (executing the batch files in the "tests" directory) worked but this one doesn't then make sure that the "java" command is starting the JVM corresponding to the java installation where you placed the JSAPI files.
To run the jsapi inside Forte or Netbeans:
1) Mount the cgjsapi.jar file.
2) Follow this path (starting at the top-level menu option): Tools->Options->Debugging & Executing->Execution Types->External Execution (if you use some other execution type, choose that instead of "External Execution")
3) Click on the "Expert" tab and edit the "Working Directory" entry to point to the directory where cgjsapi1xx.dll lives.
4) This will execute everything inside Forte/Netbeans starting at that directory - if you do not wish to do this, you could create a new execution type whose "Working Directory" is the directory where cgjsapi1xx.dll lives, and use that execution type just for your jsapi classes.
1) Under the "Tools->Configure JDKs"
option it shows you where the JDK it is using lives - for example, it may
be at "C:/JBuilder5/jdk1.3"
2) Copy the cgjsapi.jar file to "C:/JBuilder5/jdk1.3/jre/lib" and the cgjsapi1xx.dll file to "C:/JBuilder5/jdk1.3/jre/bin"
3) Then under the "Tools->Configure JDKs" option under the "Class" tab hit the "Add" button and select the "C:/JBuilder5/jdk1.3/jre/lib/cgjsapi.jar" file.
1) Under "Tools->Configure Libraries"
hit the "New" button, and then in the new dialog, type "CGJSAPI" for "Name",
hit the "Add" button and find the cgjsapi.jar file.
2) Then under "Project->Project Properties" hit the "Required Libraries" tab and "Add" the "CGJSAPI" library.
3) This lets JBuilder find the cgjsapi.jar file, but you still need to add the directory where the cgjsapi1xx.dll file lives to your system PATH variable.