Documentation for: ASP.NET Ajax Version 1.0

This documentation is for a previous version. For the current released version, see the ASP.NET Ajax documentation on MSDN.

 

 

 

 

 

 

 

NotifyScriptLoaded Property

Gets or sets a value that indicates whether the ScriptResourceHandler object automatically adds code at the end of the ECMAScript (JavaScript) file to call the notifyScriptLoaded method of the Sys.Application class.

Syntax

CSharp

[CategoryAttribute("Behavior")]
[DefaultValueAttribute(true)]
public bool NotifyScriptLoaded { get; set; }

VisualBasic

<CategoryAttribute("Behavior")> _
<DefaultValueAttribute(True)> _
Public Property NotifyScriptLoaded As Boolean

ManagedCPlusPlus

[CategoryAttribute(L"Behavior")]
[DefaultValueAttribute(true)]
public:
bool NotifyScriptLoaded {
	bool get ();
	void set (bool value);
}

JSharp

/** @property */
/** @property */

Value

Return Value

true if notifyScriptLoaded is automatically called at the end of a JavaScript file; false if code that calls notifyScriptLoaded is already in the JavaScript file. The default value is true.

Remarks

Set the NotifyScriptLoaded property to false if you reference a script file in an assembly and the script file already contains code to call notifyScriptLoaded. An error will be thrown if notifyScriptLoaded is called more than one time from a script file.

If you reference a standalone script file that is not embedded in an assembly, you must still include code at the end of the script file to call notifyScriptLoaded. The following example shows the code to include at the end of the script file.

if(typeof(Sys) !== "undefined")Sys.Application.notifyScriptLoaded();

Assembly: System.Web.Extensions (Module: System.Web.Extensions)