SpeechSynthesizer.SelectVoice Method

Selects a specific voice.

Namespace: Microsoft.Speech.Synthesis
Assembly: Microsoft.Speech (in microsoft.speech.dll)

Syntax

'Declaration

Parameters

  • name
    The requested voice name.

Remarks

Use the SpeechSynthesizer.GetInstalledVoices method and the InstalledVoice class to obtain the names of installed text-to-speech (TTS) voices.

In previous versions of Windows, Control Panel identifies TTS voices by name; for example, Microsoft Sam. In the Vista operating system, Control Panel identifies TTS voices by name and culture; for example, Microsoft Anna – English (United States). In this case, Microsoft Anna is the name of the voice and English (United States) is its culture. The name parameter passed to the SelectVoice method should specify only the name of the voice and not its culture.

Thread Safety

All public static (Shared in Visual Basic) members of this type are thread-safe. Instance members are not guaranteed to be thread-safe.

Platforms

Development Platforms

Windows XP Professional with Service Pack 2 (SP2), Windows Server 2003, Windows Vista Ultimate Edition, Windows Vista Business Edition, Windows Vista Enterprise Edition

Target Platforms

See Also

Reference

SpeechSynthesizer Class
SpeechSynthesizer Members
Microsoft.Speech.Synthesis Namespace