Assembly: System.Web.Extensions (in System.Web.Extensions.dll)
In the ScriptManager control, the version of client scripts to use is determined at run time based on the application-level element of the Web.config file, unless it is overridden in an instance of the ScriptReference control. In the ScriptReference control, when applied to a standalone script file, is equivalent to . When applied to a script reference in an assembly, is equivalent to .
The ScriptMode property of the ScriptManager object, or to the ScriptMode property of the ScriptReference object. The ScriptManager object sets the version for all scripts on the page unless it is overridden by a ScriptReference object. The ScriptReference object sets the version for a particular script.enumerator provides values for setting which version of client script to use on a Web page. The enumerator values can be applied to either the
When it is applied to a standalone script file where the Path property is specified, the value is equivalent to .
When it is applied to a script reference in an assembly, Name is specified, it is used to reference the script. When Name and the Path property are both specified, the Path property is used instead of Name, but the value is still equivalent to .is equivalent to . When only
An error is thrown if the requested version of the script does not exist. For instance, an error is thrown if a reference is made to a standalone script file that is named CustomScript.js andis set to , but CustomScript.debug.js does not exist on the site. References to scripts in an assembly return the release version if the debug version does not exist.
The following example shows a page where the script versions are declaratively set to ScriptManager control, but one script named CustomClient.js is declaratively set to in the ScriptReference control.in the
Available since 3.5