語言

FormView.CreateRow(Int32, DataControlRowType, DataControlRowState) 方法

定義

使用指定的項目索引、列類型和列狀態建立 FormViewRow 物件。

protected:
 virtual System::Web::UI::WebControls::FormViewRow ^ CreateRow(int itemIndex, System::Web::UI::WebControls::DataControlRowType rowType, System::Web::UI::WebControls::DataControlRowState rowState);
protected virtual System.Web.UI.WebControls.FormViewRow CreateRow(int itemIndex, System.Web.UI.WebControls.DataControlRowType rowType, System.Web.UI.WebControls.DataControlRowState rowState);
abstract member CreateRow : int * System.Web.UI.WebControls.DataControlRowType * System.Web.UI.WebControls.DataControlRowState -> System.Web.UI.WebControls.FormViewRow
override this.CreateRow : int * System.Web.UI.WebControls.DataControlRowType * System.Web.UI.WebControls.DataControlRowState -> System.Web.UI.WebControls.FormViewRow
Protected Overridable Function CreateRow (itemIndex As Integer, rowType As DataControlRowType, rowState As DataControlRowState) As FormViewRow

參數

itemIndex
Int32

要顯示的資料項目的零為基礎索引。

rowType
DataControlRowType

其中一個 DataControlRowType 列舉值。

rowState
DataControlRowState

列舉值的位元組合 DataControlRowState 。

傳回

FormViewRow A 具有指定的項目索引、列類型和列狀態。

備註

此 CreateRow 方法是控制項呼叫 FormView 的輔助方法,用以建立 FormViewRow 一個用來表示控制項列的物件。

給繼承者的注意事項

在擴充 FormView 類別時,你可以覆寫這個方法,回傳 FormViewRow 一個帶有自訂設定的物件。

適用於

另請參閱