如何在调用语音引擎时异步播放的问题,请帮忙!
loStream = Createobject("SAPI.SPFileStream")loVoice = Createobject("Sapi.Spvoice")
Delete File SampleVoice.wav
loStream.Open("SampleVoice.wav", 3)
loVoice.AudioOutputStream = loStream
loVoice.Voice = loVoice.GetVoices().Item(0)
loVoice.Speak("This is me Reading this Information.")
loStream.Close
loVoice.AudioOutputStream = .Null.
loStream.Open("SampleVoice.wav")
loVoice.Voice = loVoice.GetVoices().Item(0)
lovoice.speak('你好')
上面的代码调用语音引擎播放‘你好’,但在播放时会暂停程序的执行,直到播放完之后才继续执行其他代码,我想让它异步播放,也就是在播放语音的同时继续下面其他代码的执行,我能找到的资料比较少,水平也比较低,请各位高手告诉我一下,加上什么代码能异步播放呢?先谢谢了!