GridView.IDataBoundControl.DataKeyNames 屬性

定義

針對資料繫結控制項中顯示的項目,取得或設定主索引鍵欄位的名稱。

property cli::array <System::String ^> ^ System::Web::UI::WebControls::IDataBoundControl::DataKeyNames { cli::array <System::String ^> ^ get(); void set(cli::array <System::String ^> ^ value); };
string[] System.Web.UI.WebControls.IDataBoundControl.DataKeyNames { get; set; }
member this.System.Web.UI.WebControls.IDataBoundControl.DataKeyNames : string[] with get, set
 Property DataKeyNames As String() Implements IDataBoundControl.DataKeyNames

屬性值

String[]

陣列,包含 GridView 控制項中所顯示項目的主索引鍵欄位名稱。

實作

備註

這個成員是明確介面成員實作, 只有在 GridView 執行個體轉換成 IDataBoundControl 介面時,才能使用這個成員。

這個屬性可讓您存取 DataKeyNames 控制項的 GridView 屬性。 它會透過 IDataBoundControl 介面公開。

ASP.NET Dynamic Data 支援此屬性。

適用於