Alignment 列舉

定義

警告

The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.

指定所呈現物件的對齊方式。 此類別無法獲得繼承。 如需如何開發 ASP.NET 行動應用程式的資訊,請參閱 具有 ASP.NET 的Mobile Apps & Sites

public enum class Alignment
public enum Alignment
[System.Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")]
public enum Alignment
type Alignment = 
[<System.Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")>]
type Alignment = 
Public Enum Alignment
繼承
Alignment
屬性

欄位

Center 2

對齊螢幕中央。 這個 API 已經過時。 如需如何開發 ASP.NET 行動應用程式的資訊,請參閱 具有 ASP.NET 的Mobile Apps & Sites

Left 1

對齊螢幕左邊。 這個 API 已經過時。 如需如何開發 ASP.NET 行動應用程式的資訊,請參閱 具有 ASP.NET 的Mobile Apps & Sites

NotSet 0

預設值。 如果數值是 NotSet,則會從控制項的樣式繼承對齊方式,或者如果沒有定義樣式,則會從控制項的父控制項繼承對齊方式。 這個 API 已經過時。 如需如何開發 ASP.NET 行動應用程式的資訊,請參閱 具有 ASP.NET 的Mobile Apps & Sites

Right 3

對齊螢幕右邊。 這個 API 已經過時。 如需如何開發 ASP.NET 行動應用程式的資訊,請參閱 具有 ASP.NET 的Mobile Apps & Sites

備註

列舉 Alignment 表示專案在其父容器上的水準位置,例如面板或窗體。 例如,如果您將影像新增至窗體,您可以設定其水準位置,使其與窗體右側對齊。

雖然您可以在腳本語言中使用位值,但不能搭配使用 ASP.NET。 例如, Alignment = "2" 在面板標籤內不是有效的語句。 不過,在 Visual C# 中,您可以使用 this.myPanel.Alignment = 2

適用於