System.Web.Hosting.HostingEnvironment.SetCultures Method

Sets the current thread to the culture of the specified virtual path.

Syntax

public static IDisposable SetCultures (string virtualPath)

Parameters

virtualPath
The path that contains the culture information.

Returns

An IDisposable object that represents the culture prior to changing; this object can be used to revert to the previous culture.

Remarks

The HostingEnvironment.SetCultures(string) method sets the current thread to the culture that results after applying all globalization elements in the configuration files affecting the specified virtual path.

Requirements

Namespace: System.Web.Hosting
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0