Introduction
Today, I am providing a working example of text to speech using .Net framework 4.5 with System.Text namespace. Text to speech is used widely in large scale for different purposes.I am explaining all steps how to convert Text to Speech using C#, .Net framework.
Step 1. First of all, we have to add reference of System.Speech in our Text Speech application.
Step 2. Now import namespace using System.Speech.Synthesis in our form.
using System.Speech.Synthesis;Step 3. Now create object of SpeechSynthesizer
SpeechSynthesizer speech = new SpeechSynthesizer();Step 4. Next one, write this line code speech.SpeakAsync(textBox1.Text) on button click.
speech.SpeakAsync(textBox1.Text);Step 5. Run application using F5 button to view Text speech interface.
Step 6. Enter sample text in input box to read through our application.
Step 7. Finally you can see how gracefully reading our text using our C# application.
Summary
Explained above, all steps Text to Speech using C# .Net framework 4.5 with working sample. I have attached working sample at the bottom of this article.If anybody need help or further queries then write here.
You need to check with server settings
ReplyDelete