TemplateControl.GetLocalResourceObject Method (String)

Gets a page-level resource object based on the specified ResourceKey property.

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

protected:
Object^ GetLocalResourceObject (
	String^ resourceKey
)
protected Object GetLocalResourceObject (
	String resourceKey
)
protected function GetLocalResourceObject (
	resourceKey : String
) : Object
Not applicable.

Parameters

resourceKey

A string representing a ResourceKey.

Return Value

An object representing the requested resource object; otherwise, a null reference (Nothing in Visual Basic).

Local resource files are stored in the App_LocalResources directory. For more information, see Resources in ASP.NET Applications

The following code example demonstrates how to use the GetLocalResourceObject method to access a string named LocalResourceString1 from a local page resource that is located in the App_LocalResources folder.

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

Windows 98, Windows Server 2000 SP4, 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: