Version

ResolveAndRegisterClientScriptInclude(String,String,String,String,Control,String,Type) Method

Determines what Javascript resource a calling control can use according to the parameter values specified, and registers a client-script block that will include it at render-time.
Syntax
'Declaration
 
Public Overloads Shared Function ResolveAndRegisterClientScriptInclude( _
   ByVal defaultValue As String, _
   ByVal embeddedResourcePath As String, _
   ByVal propertyValue As String, _
   ByVal fileName As String, _
   ByVal control As Control, _
   ByVal key As String, _
   ByVal registerWithType As Type _
) As String
public static string ResolveAndRegisterClientScriptInclude( 
   string defaultValue,
   string embeddedResourcePath,
   string propertyValue,
   string fileName,
   Control control,
   string key,
   Type registerWithType
)

Parameters

defaultValue
This is the control's default value, and can be null (Nothing in Visual Basic .NET) for assemblies built with CLR 2.0 or later.
embeddedResourcePath
Name used to retreive the .js file from the assembly as an embedded resource. This value can be null (Nothing in Visual Basic .NET) for CLR 1.x assemblies.
propertyValue
Actual value specified for the property on the control.
fileName
This is the .js filename only, without any directories, etc.
control
A control reference requiring inclusion of this Javascript file.
key
The key value as a String, used when including this Javascript. Subsequent registrations using the same key value are ignored by the ASP.NET Framework.
registerWithType
The CLR Type used to determine the assembly containing the resource, if embedded.

Return Value

String which the calling control can use to reference the resource.
Remarks

Only one of the arguments, defaultValue or embeddedResourcePath, must be specified as a valid String.

Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also