共用方式為


ContentControl.OnContentTemplateChanged(DataTemplate, DataTemplate) 方法

定義

ContentTemplate 屬性變更時呼叫。

protected:
 virtual void OnContentTemplateChanged(System::Windows::DataTemplate ^ oldContentTemplate, System::Windows::DataTemplate ^ newContentTemplate);
protected virtual void OnContentTemplateChanged (System.Windows.DataTemplate oldContentTemplate, System.Windows.DataTemplate newContentTemplate);
abstract member OnContentTemplateChanged : System.Windows.DataTemplate * System.Windows.DataTemplate -> unit
override this.OnContentTemplateChanged : System.Windows.DataTemplate * System.Windows.DataTemplate -> unit
Protected Overridable Sub OnContentTemplateChanged (oldContentTemplate As DataTemplate, newContentTemplate As DataTemplate)

參數

oldContentTemplate
DataTemplate

ContentTemplate 屬性的舊值。

newContentTemplate
DataTemplate

ContentTemplate 屬性的新值。

適用於