Grammar.LoadLocalizedGrammarFromType Method (Type, Object[])


The LoadLocalizedGrammarFromType method returns a localized instance of a Grammar object derived from Type.

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

public static Grammar LoadLocalizedGrammarFromType(
	Type type,
	params object[] onInitParameters


Type: System.Type

In an assembly, the Type of an object based on Grammar.

Type: System.Object[]

Parameters to be passed to an initialization method of the localizedobject based on Grammar. This parameter may be null.

Return Value

Type: System.Speech.Recognition.Grammar

The LoadLocalizedGrammarFromType method returns a valid object based on Grammar, or null if there has been an error.

Localized grammars obtained with LoadLocalizedGrammarFromType are typically strongly-typed (see IsStg for more information on strongly typed grammars). If onInitParameters is a null reference (Nothing in Visual Basic) the localized grammar should have either no initialization method, or a method that takes no arguments.

.NET Framework
Available since 3.0
Return to top