This documentation is archived and is not being maintained.

RecognizeMode Enumeration

Enumerates values of the recognition mode.

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

public enum RecognizeMode
public enum RecognizeMode
public enum RecognizeMode

Member nameDescription
Multiple Specifies that recognition does not terminate after completion.
Single Specifies that recognition terminates after completion.

This enumeration is used as an argument to RecognizeAsync

In the following example show the implementation of a start/stop button for a application with a graphical user interface using SpeechRecognitionEngine. Depending on the state of the application, when the button is clicked RecognizeAsync is called with either Single or Multiple.

private void _startRecogButton_Click(object sender, EventArgs eventArgs) {
    if (_startRecogButton.Text == "Start Speech Recognition") { //Toggle Speech Recogniztion on
        _startRecogButton.Text = "Stop Speech Recognition";
        if (_useMultiple) {
        } else {
    } else {                                                      //Toggle Speech Recognition off
        _startRecogButton.Text = "Start Speech Recognition";
        if (_friendlyStop) {
            _recognitionEngine.RecognizeAsyncStop(); //Stop after current phrase is finished.
        } else {
            _recognitionEngine.RecognizeAsyncCancel(); //Stop before current phrase is finished.


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