Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
TTS in VFP
Message
De
20/02/2006 19:34:27
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
TTS in VFP
Versions des environnements
Visual FoxPro:
VFP 7
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01097628
Message ID:
01097628
Vues:
66
In order to create a TTS application I'd converted a microsoft TTS sample but the feature which highlight every spoken word had been very tricky.

This task is achieved binding with EVENTHANLDER statement the object Voice with one of its methods called ISpVoice_Word so.

In the init method of the form must appear

loVoiceEngine= CREATEOBJECT("SAPI.SpVoice")

LOCAL oEvents
oEvents = NEWOBJECT("voice_methods") && generate error
EVENTHANDLER(loVoiceEngine, oEvents)



The class are define in the calling prg.

DEFINE CLASS voice_methods AS custom OLEPUBLIC
IMPLEMENT ISpVoice IN sapi.SpVoice

Procedure ISpVoice_Word(StreamNum As Long, StreamPos As Variant,;
Pos As Long, Length As Long)
xpos=pos
mlength=mlength
ochineseform.highlightspokenwords(pos,mlength)
ENDPROC

I got the error


Class cannot be instantiated because Member ISPVOICE_GetOutputObjectToken does not exist.

In the microsoft sample this member is not needed.

Does someone understand this behaviour or have expericnce using SAPI5 in VFP?

The Foxpro Advisor sample of 2001 only show a voice recognizer form.

Thanks in advance

Alejandro Fernandez
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform