Gets the culture that the current thread uses for retrieving culture-specific resources.
' Usage Dim value As System.Globalization.CultureInfo = My.Application.UICulture ' Declaration Public ReadOnly Property UICulture As System.Globalization.CultureInfo
Returns a CultureInfo object that represents the culture that the current thread uses for retrieving culture-specific resources.
The My.Application.CurrentUICulture property gets the CultureInfo object that the current thread uses for retrieving culture-specific resources. This object is identical to the one returned by the CurrentUICulture property. The CurrentUICulture property determines the culture used by the Resource Manager and the My.Resources object, information it needs to look up culture-specific resources at run time.
The CurrentCulture setting is different from a language setting. It contains only data related to the standard settings for a geographical region.
Use the My.Application.CurrentCulture property to get the culture that the current thread uses for string manipulation and string formatting.
This example uses the My.Application.CurrentCulture property to cache the current culture, before changing it with the My.Application.ChangeUICulture Method. The My.Application.ChangeUICulture method sets the culture that the My.Resources Object uses for retrieving resources.
For this example to work, your application must have a string named Message in the application's resource file, and the application should have the French-culture version of that resource file, Resources.fr-FR.resx. For more information, see How to: Add or Remove Resources.
If the application does not have the French-culture version of that resource file, the My.Resource object retrieves the resource from the default-culture resource file.
Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)
Availability by Project Type
Windows Control Library
Web Control Library