BindableAttribute Constructor
Collapse the table of content
Expand the table of content
This documentation is archived and is not being maintained.

BindableAttribute Constructor

.NET Framework 1.1

Initializes a new instance of the BindableAttribute class.

Overload List

Initializes a new instance of the BindableAttribute class with one of the BindableSupport values.

[Visual Basic] Public Sub New(BindableSupport)
[C#] public BindableAttribute(BindableSupport);
[C++] public: BindableAttribute(BindableSupport);
[JScript] public function BindableAttribute(BindableSupport);

Initializes a new instance of the BindableAttribute class with a Boolean value.

[Visual Basic] Public Sub New(Boolean)
[C#] public BindableAttribute(bool);
[C++] public: BindableAttribute(bool);
[JScript] public function BindableAttribute(Boolean);


[Visual Basic, C#, C++] The following example marks a property as appropriate to bind data to. This code creates a new BindableAttribute, sets its value to BindableAttribute.Yes, and binds it to the property.

[Visual Basic, C#, C++] Note   This example shows how to use one of the overloaded versions of the BindableAttribute constructor. For other examples that might be available, see the individual overload topics.
[Visual Basic] 
<Bindable(true)> _
Public Property MyProperty As Integer
      ' Insert code here.
      Return 0
   End Get
      ' Insert code here.
   End Set
End Property

 public int MyProperty {
    get {
       // Insert code here.
       return 0;
    set {
       // Insert code here.

__property int get_MyProperty() 
    // Insert code here.
    return 0;
__property void set_MyProperty( int theValue ) 
    // Insert code here.

[JScript] No example is available for JScript. To view a Visual Basic, C#, or C++ example, click the Language Filter button Language Filter in the upper-left corner of the page.

See Also

BindableAttribute Class | BindableAttribute Members | System.ComponentModel Namespace

© 2016 Microsoft