Label.SupportsDisabledAttribute Label.SupportsDisabledAttribute Label.SupportsDisabledAttribute Label.SupportsDisabledAttribute Property

定义

获取一个值,该值指示在控件的 IsEnabled 属性为 disabled 时,控件是否应将呈现的 HTML 元素的 false 特性设置为“disabled”。Gets a value that indicates whether the control should set the disabled attribute of the rendered HTML element to "disabled" when the control's IsEnabled property is false.

public:
 virtual property bool SupportsDisabledAttribute { bool get(); };
public override bool SupportsDisabledAttribute { get; }
member this.SupportsDisabledAttribute : bool
Public Overrides ReadOnly Property SupportsDisabledAttribute As Boolean

属性值

true如果属性指示 ASP.NET 版本低于4.0false则为; 否则为。 RenderingCompatibilitytrue if the RenderingCompatibility property indicates an ASP.NET version lower than 4.0; otherwise, false.

注解

此属性指示在控件被禁用时 ASP.NET 应如何呈现控件的 HTML。This property indicates how ASP.NET should render HTML for a control when the control is disabled. 如果此属性为true,则在禁用disabled控件时,ASP.NET 将呈现属性。If this property is true, ASP.NET renders a disabled attribute when a control is disabled. 如果此属性为false,则在禁用class控件时,ASP.NET 将呈现属性。If this property is false, ASP.NET renders a class attribute when a control is disabled. 有关详细信息,请参阅 WebControl.SupportsDisabledAttributeFor more information, see WebControl.SupportsDisabledAttribute.

适用于

另请参阅