Click here to Skip to main content
15,896,269 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
When I speak the voice through SpeechLib.dll it is working fine.

To Speak the voice here is the code:
C#
voice.Voice = voice.GetVoices().Item(ddlVoices.SelectedIndex);
voice.Volume = trackBarVolume.Value;
voice.Rate = trackBarSpeed.Value;
speakingText = txtUserInput.Text;
voice.Speak(speakingText, SpeechLib.SpeechVoiceSpeakFlags.SVSFlagsAsync);

In the middle of the speaking text i have Pause the speaking like:
voice.Pause();

After that I want to stop the voice and speak the voice with different senatnce. To stop the voice I have used:
C#
voice.Speak("", SpeechLib.SpeechVoiceSpeakFlags.SVSFPurgeBeforeSpeak);

In this scenario when I call stop method I got the below error:

Exception from HRESULT: 0x80045006

And it take lot of time to give the responce.
Posted
Updated 12-Sep-11 1:34am
v2

1 solution

 
Share this answer
 
Comments
Member 3827009 12-Sep-11 8:12am    
Hi,

That i understand the issue with the Error code. How to resolve this issue need the solution to resolve.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900