Search code examples
vbscriptsapi

Visual Basic Script , SAPI , accessing AT&T Natural Voices


I have a question regarding SAPI and AT&T Natural Voices. Please can you advise me if it is possible to access AT&T Natural Voices using SAPI and Visual Basic Script (vbscript).

I have four voices total installed on my Windows 7 PC. Two AT&T voices and two voices from another vendor (Cepstral) :-

Reiner16.exe  (file version 1.4.0.0)
Klara16.exe   (file version 1.4.0.0)
Cepstral_Matthias_windows_6.2.3.670.exe
Cepstral_Katrin_windows_6.2.3.670.exe

I am running the following Visual Basic Script to list all installed voices :-

Set objVoice = CreateObject("Sapi.SpVoice")
For Each T In objVoice.GetVoices
    Wscript.Echo T.GetDescription
Next
Set objVoice = Nothing

This Visual Basic Script only lists the two Cepstral voices and it does not list the two AT&T voices ?

Please can you advise me if it is possible to access AT&T Natural Voices using SAPI and Visual Basic Script (vbscript).

Thank you for your time,

Best regards,

James


Solution

  • I have the SOLUTION to this problem.

    The solution is to run the vbscript using the following command :-

    %windir%\SysWoW64\cmd.exe /C "MyScript.VBS"
    

    This command forces Windows 7 to run the vbscript in 32 bit mode instead of default 64 bit mode. In 64 bit mode, it only sees 64 bit voices. In 32 bit mode, it can see 32 bit voices.

    Thanks,

    James