MergablePropertyAttribute(Boolean) 생성자

정의

MergablePropertyAttribute 클래스의 새 인스턴스를 초기화합니다.

public:
 MergablePropertyAttribute(bool allowMerge);
public MergablePropertyAttribute (bool allowMerge);
new System.ComponentModel.MergablePropertyAttribute : bool -> System.ComponentModel.MergablePropertyAttribute
Public Sub New (allowMerge As Boolean)

매개 변수

allowMerge
Boolean

이 속성을 속성 창에 있는 다른 개체의 속성과 결합할 수 있으면 true이고, 그렇지 않으면 false입니다.

예제

다음 예에서는 merge에 적합 한 속성을 표시 합니다. 이 코드를 만듭니다 MergablePropertyAttribute, 그 값을 설정 MergablePropertyAttribute.Yes, 속성에 바인딩합니다.

public:
   [MergableProperty(true)]
   property int MyProperty 
   {
      int get()
      {
         // Insert code here.
         return 0;
      }
      void set( int value )
      {
         // Insert code here.
      }
   }

[MergableProperty(true)]
public int MyProperty {
   get {
      // Insert code here.
     return 0;
   }
   set {
      // Insert code here.
   }
}
<MergableProperty(True)> _    
Public Property MyProperty() As Integer
    Get
        ' Insert code here.
        Return 0
    End Get
    Set
        ' Insert code here.
    End Set 
End Property

적용 대상

추가 정보