IResourceProvider.GetObject Method

Returns a resource object for the key and culture.

Namespace: System.Web.Compilation
Assembly: System.Web (in system.web.dll)

Object^ GetObject (
	String^ resourceKey, 
	CultureInfo^ culture
)
Object GetObject (
	String resourceKey, 
	CultureInfo culture
)
function GetObject (
	resourceKey : String, 
	culture : CultureInfo
) : Object
Not applicable.

Parameters

resourceKey

The key identifying a particular resource.

culture

The culture identifying a localized value for the resource.

Return Value

An Object that contains the resource value for the resourceKey and culture.

When implemented, the GetObject method returns the localized value for a resource key based on the current culture. The implementing class could retrieve the CurrentUICulture property if a value for the culture parameter is not passed in.

The following code example shows a customized resource provider factory that retrieves cached values. The resource provider factory creates an instance of a customized resource provider that implements IResourceProvider. The resource provider includes a customized GetObject method.

No code example is currently available or this language may not be supported.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions

ADD
Show: