TableItemStyle.VerticalAlign 屬性

定義

取得或設定儲存格中內容的垂直對齊。Gets or sets the vertical alignment of the contents in a cell.

public:
 virtual property System::Web::UI::WebControls::VerticalAlign VerticalAlign { System::Web::UI::WebControls::VerticalAlign get(); void set(System::Web::UI::WebControls::VerticalAlign value); };
[System.ComponentModel.Bindable(true)]
public virtual System.Web.UI.WebControls.VerticalAlign VerticalAlign { get; set; }
public virtual System.Web.UI.WebControls.VerticalAlign VerticalAlign { get; set; }
[<System.ComponentModel.Bindable(true)>]
member this.VerticalAlign : System.Web.UI.WebControls.VerticalAlign with get, set
member this.VerticalAlign : System.Web.UI.WebControls.VerticalAlign with get, set
Public Overridable Property VerticalAlign As VerticalAlign

屬性值

VerticalAlign

其中一個 VerticalAlign 列舉值。One of the VerticalAlign enumeration values. 預設為 NotSetThe default is NotSet.

屬性

例外狀況

指定的垂直對齊不是其中一個 VerticalAlign 列舉值。The specified vertical alignment was not one of the VerticalAlign enumeration values.

備註

VerticalAlign 可以使用屬性來指定資料格內容的垂直對齊方式。Use the VerticalAlign property to specify the vertical alignment of the contents of the cell. 下表列出可能的值。The following table lists the possible values.

垂直對齊方式Vertical Alignment 描述Description
NotSet 未設定垂直對齊。The vertical alignment is not set.
Top 儲存格的內容與資料格的上邊緣對齊。The contents of the cell are aligned with the upper edge of the cell.
Middle 儲存格的內容會與資料格的中心對齊。The contents of the cell are aligned with the center of the cell.
Bottom 儲存格的內容會與資料格的下邊緣對齊。The contents of the cell are aligned with the lower edge of the cell.

這個屬性的值會儲存在 view 狀態中。The value of this property is stored in view state.

適用於