PromptBuilder::AppendAudio Method (Uri^)
.NET Framework (current version)
Appends the audio file at the specified URI to the PromptBuilder.
Assembly: System.Speech (in System.Speech.dll)
Parameters
- audioFile
-
Type:
System::Uri^
URI for the audio file.
The following example initializes a new instance of the PromptBuilder class and then adds text to it, followed by an audio file.
using System.Speech.PromptBuilder; public void SimpleConcatenation() { // Add a prompt fragment from a .wav file. PromptBuilder builder = new PromptBuilder (); builder.AppendText("How are you today?"); builder.AppendAudio(new Uri ("http://www.speech.microsoft.com/ding.wav")); }
The following markup shows the equivalent SSML markup.
<speak xmlns="http://www.w3.org/2001/10/synthesis" xmlns:ms="http://www.microsoft.com/speech/synthesis" xml:lang="en"> How are you today? <audio src="http://www.speech.microsoft.com/ding.wav" /> </speak>
.NET Framework
Available since 3.0
Available since 3.0
Show: