語言

DataControlFieldDesigner.GetNewDataSourceName 方法

定義

當資料欄位轉換成 TemplateField.

protected:
 System::String ^ GetNewDataSourceName(Type ^ controlType, System::Web::UI::WebControls::DataBoundControlMode mode);
protected string GetNewDataSourceName(Type controlType, System.Web.UI.WebControls.DataBoundControlMode mode);
member this.GetNewDataSourceName : Type * System.Web.UI.WebControls.DataBoundControlMode -> string
Protected Function GetNewDataSourceName (controlType As Type, mode As DataBoundControlMode) As String

參數

controlType
Type

將建立的控制類型。

mode
DataBoundControlMode

控制系統的資料輸入模式。

傳回

控制的 ID 是唯一的。

備註

此 GetNewDataSourceName 方法是一種輔助方法,方法可用 CreateTemplateField 來產生唯一控制項的 ID,這些 ID 在你點擊將資料欄位轉換成 TemplateField 欄位編輯器的連結時所建立。

適用於