How can I with the TTS Control(Direct speech control) speak a paragraph with any of this Languages using the control properties?.I am not able to do it
Never uses L&H but the Microsoft speech sdk 5.1 works. Add a reference
to the Microsoft speech object lib 5.0 in the com tab. You can download
the sdk here.
This example assumes you have a textbox named txtspeak, and button
named btnsay
Dim tts As SpeechLib.SpVoice
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
tts = New SpeechLib.SpVoice
btnSay.PerformClick()
End Sub
Private Sub btnSay_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSay.Click
tts.Speak(txtSpeak.Text,
SpeechLib.SpeechVoiceSpeakFlags.SVSFlagsAsync)
End Sub
I can get 4 voices in sapi 5.1 (mary,mike,sam and another one) what I do not know is how to get the T&H engines
for the other four the code comes in the sdk.Here it is
Dim WithEvents Voice As SpeechLib.SpVoic
' Creates the voice object firs
Voice = New SpeechLib.SpVoic
Dim Token As SpeechLib.ISpeechObjectToke
For Each Token In Voice.GetVoice
VoiceCB.Items.Add((Token.GetDescription())
Next Toke
VoiceCB.SelectedIndex =
Voice.Voice = Voice.GetVoices().Item(VoiceCB.SelectedIndex
Voice.Speak("hello I'm tired"
VoiceCB.SelectedIndex =
Voice.Voice = Voice.GetVoices().Item(VoiceCB.SelectedIndex
Voice.Speak("you have to rest")
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.