ScriptManager.ScriptMode Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets a value that specifies whether debug or release versions of client script libraries are rendered.
public:
property System::Web::UI::ScriptMode ScriptMode { System::Web::UI::ScriptMode get(); void set(System::Web::UI::ScriptMode value); };
public System.Web.UI.ScriptMode ScriptMode { get; set; }
member this.ScriptMode : System.Web.UI.ScriptMode with get, set
Public Property ScriptMode As ScriptMode
Property Value
The enumeration value that indicates the current mode. The default is Auto.
Exceptions
The ScriptMode property is not one of the ScriptMode values.
Remarks
The ScriptMode property specifies whether the ScriptManager control should render debug or release versions of client script libraries. This value can be superseded by values that are set in the configuration file and in the page directive.
The following table lists the valid values for this property.
Value | Definition |
---|---|
Auto | Debug versions of client script libraries are used in the Web page when the retail attribute of the deployment configuration element is set to false . Otherwise, the release versions of client script libraries are used. |
Inherit | When applied to the ScriptMode property of the ScriptManager object, this value is the same as Auto. |
Debug | Debug versions of client script libraries are used in the Web page unless the retail attribute of the deployment configuration element is set to true . |
Release | Release versions of client script libraries are used in the Web page unless the retail attribute of the deployment configuration element is set to false . |
Note
The debug
attribute of the @ Page directive does not affect Ajax-enabled ASP.NET applications. The ScriptManager control uses only the settings in the Web.config file and in its IsDebuggingEnabled and ScriptMode properties to determine whether to render debug scripts.
For more information, see Debugging and Tracing Ajax Applications Overview.
Applies to
See also
.NET
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기