BindableAttribute.Bindable プロパティとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > BindableAttribute.Bindable プロパティの意味・解説 

BindableAttribute.Bindable プロパティ

プロパティ通常バインド使用されることを示す値を取得します

名前空間: System.ComponentModel
アセンブリ: System (system.dll 内)
構文構文

使用例使用例

MyPropertyバインドできるかどうか確認するコード例次に示します最初に、次を実行することによって、MyProperty属性取得します

次にmyAttribute を AttributeCollection にある BindableAttribute の値に設定しプロパティバインドできるかどうか確認します

このコード例実行するには、アセンブリの完全修飾名を指定する必要がありますアセンブリの完全修飾名を取得する方法については、

アセンブリ名.

' Gets the attributes for the property.
Dim attributes As AttributeCollection = _
   TypeDescriptor.GetProperties(Me)("MyProperty").Attributes
 
     ' Checks to see if the property is bindable.
     Dim myAttribute As BindableAttribute =
 _
     CType(attributes(System.Type.GetType("BindableAttribute")),
 BindableAttribute)
     If (myAttribute.Bindable) Then
         ' Insert code here.
     End If

// Gets the attributes for the property.
 AttributeCollection attributes = 
    TypeDescriptor.GetProperties(this)["MyProperty"].Attributes;
 
     // Checks to see if the property is bindable.
     BindableAttribute myAttribute = (BindableAttribute)attributes[typeof(BindableAttribute)];
     if(myAttribute.Bindable) 
     {
         // Insert code here.
     }

// Gets the attributes for the property.
AttributeCollection^ attributes = TypeDescriptor::GetProperties( this
 )[ "MyProperty" ]->Attributes;

// Checks to see if the property is bindable.
BindableAttribute^ myAttribute = dynamic_cast<BindableAttribute^>(attributes[
 BindableAttribute::typeid ]);
if ( myAttribute->Bindable )
{
   // Insert code here.
}
// Gets the attributes for the property.
AttributeCollection attributes =
    TypeDescriptor.GetProperties(this).get_Item("MyProperty").
    get_Attributes();

// Checks to see if the property is bindable.
// You must supply a valid fully qualified assembly name here. 
BindableAttribute myAttribute =
    (BindableAttribute)(attributes.get_Item(Type.GetType
    ("Assembly text name, Version, Culture, PublicKeyToken")));
if (myAttribute.get_Bindable()) {
    // Insert code here.
}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
BindableAttribute クラス
BindableAttribute メンバ
System.ComponentModel 名前空間
BindableAttribute クラス
Attribute
PropertyDescriptor
AttributeCollection クラス
PropertyDescriptorCollection



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「BindableAttribute.Bindable プロパティ」の関連用語

BindableAttribute.Bindable プロパティのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



BindableAttribute.Bindable プロパティのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS