Share via


FilterableAttribute.Filterable 속성

정의

FilterableAttribute 특성이 적용된 속성이 디바이스 필터링을 지원하는지 여부를 나타내는 값을 가져옵니다.

public:
 property bool Filterable { bool get(); };
public bool Filterable { get; }
member this.Filterable : bool
Public ReadOnly Property Filterable As Boolean

속성 값

Boolean

특성이 적용된 속성이 디바이스 필터링을 지원함을 나타내려면 true이고, 그렇지 않으면 false입니다.

예제

다음 코드 예제에 적용 하는 방법을 보여 줍니다.는 FilterableAttribute 특성를 나타내는 속성이 디바이스 필터링을 지원 하지 않는 사용자 지정 컨트롤의 속성입니다.


using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Text;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Samples.AspNet.CS.Controls
{
    public class SimpleCustomControl : WebControl
    {
        private string _productID;

        // Set Filterable attribute to specify that this
        // property does not support device filtering.
        [Bindable(true)]
        [Filterable(false)]
        public string ProductID
        {
            get
            {
                return _productID;
            }
            set
            {
                _productID = value;
            }
        }
    }
}

Imports System.ComponentModel
Imports System.Web.UI

Namespace Samples.AspNet.VB.Controls

    Public Class SimpleCustomControl
        Inherits System.Web.UI.WebControls.WebControl

        Dim _productID As String

        ' Set Filterable attribute to specify that this
        ' property does not support device filtering.
        <Bindable(True), Filterable(False)> Property ProductID() As String
            Get
                Return _productID
            End Get

            Set(ByVal Value As String)
                _productID = Value
            End Set
        End Property
    End Class

End Namespace

설명

사용 합니다 Filterable 속성을 여부를 속성을는 FilterableAttribute 특성이 적용 되 디바이스 필터링을 지원 합니다. 속성이 디바이스 필터링을 지 원하는 경우에 디바이스 필터를 지정 하 여 특정 디바이스에 대 한 속성의 값을 재정의할 수 있습니다. 자세한 내용은 특정 디바이스에 대 한 사용자 지정합니다.

적용 대상

추가 정보