InputLanguageManager.CurrentInputLanguage Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets or sets the current input language.

Namespace:   System.Windows.Input
Assembly:  PresentationCore (in PresentationCore.dll)

[TypeConverterAttribute(typeof(CultureInfoIetfLanguageTagConverter))]
public CultureInfo CurrentInputLanguage { get; set; }

Property Value

Type: System.Globalization.CultureInfo

A CultureInfo object representing the currently selected input language. This property may not be set to null.

The default value is InvariantCulture.

Exception Condition
ArgumentNullException

Raised when an attempt is made to set this property to null.

The following example demonstrates how to use an InputLanguageManager to get the current input language.

InputLanguageManager.SetInputLanguage(tb1, CultureInfo.CreateSpecificCulture("fr"));
tb1.Text = "Current Input Language is " + InputLanguageManager.Current.CurrentInputLanguage.ToString();

.NET Framework
Available since 3.0
Return to top
Show: