Page.StyleSheetTheme Page.StyleSheetTheme Page.StyleSheetTheme Page.StyleSheetTheme Property

定義

取得或設定在網頁生命週期早期套用至網頁的佈景主題名稱。Gets or sets the name of the theme that is applied to the page early in the page life cycle.

public:
 virtual property System::String ^ StyleSheetTheme { System::String ^ get(); void set(System::String ^ value); };
[System.ComponentModel.Browsable(false)]
public virtual string StyleSheetTheme { get; set; }
member this.StyleSheetTheme : string with get, set
Public Overridable Property StyleSheetTheme As String

屬性值

在網頁生命週期早期套用至網頁的佈景主題名稱。The name of the theme that is applied to the page early in the page life cycle.

例外狀況

已嘗試於 StyleSheetTheme 方法叫用後設定 FrameworkInitialize() 屬性。An attempt was made to set the StyleSheetTheme property after the FrameworkInitialize() method was called.

StyleSheetTheme 是設為無效的主題名稱。StyleSheetTheme is set to an invalid theme name. FrameworkInitialize() 方法不是由屬性 setter 呼叫時,擲回此例外狀況。This exception is thrown when the FrameworkInitialize() method is called, not by the property setter.

備註

這個屬性不是指直接階層式樣式表 (CSS)。This property does not refer directly to a cascading style sheet (CSS). 屬性包含 ASP.NET 主題,其中可以包括其內的 CSS 檔案的名稱。The property contains the name of an ASP.NET theme, which can include CSS files within it.

StyleSheetTheme屬性會指定在頁面生命週期早期套用至頁面的佈景主題的名稱,而Theme屬性會指定在網頁生命週期的稍後套用至頁面的佈景主題的名稱。The StyleSheetTheme property specifies the name of a theme that is applied to a page early in the page life cycle, whereas the Theme property specifies the name of a theme that is applied to a page later in the page life cycle. 這表示,在頁面上的設定值優先於樣式表主題中的設定。This means that settings on the page take precedence over settings in the style sheet theme. 如需詳細資訊,請參閱 < ASP.NET 佈景主題和面板For more information, see ASP.NET Themes and Skins.

在 page 指示詞,或藉由覆寫屬性中,通常會設定這個屬性的值。You typically set a value for this property in the page directive or by overriding the property. 資訊,請參閱下列主題:For information, see the following topics:

適用於

另請參閱