Style.MergeWith(Style) 方法

定義

將指定的 Style 的樣式屬性與呼叫這個方法的 Style 類別的執行個體組合在一起。Combines the style properties of the specified Style with the instance of the Style class that this method is called from.

public:
 virtual void MergeWith(System::Web::UI::WebControls::Style ^ s);
public virtual void MergeWith (System.Web.UI.WebControls.Style s);
abstract member MergeWith : System.Web.UI.WebControls.Style -> unit
override this.MergeWith : System.Web.UI.WebControls.Style -> unit
Public Overridable Sub MergeWith (s As Style)

參數

s
Style

Style,表示要合併的樣式。A Style that represents the style to combine.

例外狀況

備註

使用方法,將指定Style之的樣式屬性Style與呼叫此方法的類別實例結合。 MergeWithUse the MergeWith method to combine the style properties of the specified Style with the instance of the Style class that this method is called from.

警告

除了已在樣式類別的目前實例上設定的屬性以外,所有屬性都會由Style s參數所指定之的對應屬性來取代。All properties, except those that have already been set on the current instance of the Style class, will be replaced by the corresponding property of the Style specified by the s parameter.

適用於

另請參閱