IAttributeAccessor.GetAttribute メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > IAttributeAccessor.GetAttribute メソッドの意味・解説 

IAttributeAccessor.GetAttribute メソッド

クラスによって実装された場合は、指定した属性プロパティサーバー コントロールから取得します

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

Function GetAttribute ( _
    key As String _
) As String
Dim instance As IAttributeAccessor
Dim key As String
Dim returnValue As String

returnValue = instance.GetAttribute(key)
string GetAttribute (
    string key
)
String^ GetAttribute (
    String^ key
)
String GetAttribute (
    String key
)
function GetAttribute (
    key : String
) : String

パラメータ

key

サーバー コントロール属性の名前を表す String

戻り値
指定した属性の値。

使用例使用例

GetAttribute メソッド実装する方法次のコード例示します

' Implement the GetAttribute method for the control. When
' this method is called from a page, the values for the control's
' properties can be displayed in the page.
Public Function GetAttribute(name As
 String) As String Implements
 IAttributeAccessor.GetAttribute
   Return CType(ViewState(name), String)
End Function 'GetAttribute

// Implement the GetAttribute method for the control. When
// this method is called from a page, the values for the control's
// properties can be displayed in the page.
public String GetAttribute(String name)
{
   return (String)ViewState[name];
}
// Implement the GetAttribute method for the control. When
// this method is called from a page, the values for the control's
// properties can be displayed in the page.
public String GetAttribute(String name)
{
    return (String)(this.get_ViewState().get_Item(name));
} //GetAttribute
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
IAttributeAccessor インターフェイス
IAttributeAccessor メンバ
System.Web.UI 名前空間



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

辞書ショートカット

すべての辞書の索引

「IAttributeAccessor.GetAttribute メソッド」の関連用語

IAttributeAccessor.GetAttribute メソッドのお隣キーワード
検索ランキング

   

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



IAttributeAccessor.GetAttribute メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

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

©2025 GRAS Group, Inc.RSS