Loaded Property

Microsoft Speech Platform SDK 11

Collapse imageExpand ImageCopy imageCopyHover image

Gets whether a Grammar has been loaded by a recognition engine.

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

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Loaded As Boolean
	Get
Visual Basic (Usage)
Dim instance As Grammar
Dim value As Boolean

value = instance.Loaded
C#
public bool Loaded { get; }

Property Value

Type: System..::..Boolean

The Loaded property returns true if the referenced speech recognition grammar is currently loaded in a recognition engine; otherwise the property returns false. The default is false.

Remarks

Once a Grammar has been loaded, the values of Weight, and Priority cannot be changed.

Examples

In the example below, the application checks to see if the Grammar is loaded before changing the value for Priority.

C# Copy imageCopy Code
if (!(_grammar.Loaded))
{
  Grammar.Priority=5;
}

See Also