C# 文字語音應用 - NET組件

使用NET 組件,讓電腦開口說話

加入參考

新增引用

using System.Speech.Synthesis;

撰寫程序

string msg = txtSpeech.Text;
SpeechSynthesizer synth = new SpeechSynthesizer();
synth.SpeakAsync(msg);