ItemContainerTemplateSelector.SelectTemplate(Object, ItemsControl) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
When overridden in a derived class, returns an ItemContainerTemplate based on custom logic.
public:
virtual System::Windows::DataTemplate ^ SelectTemplate(System::Object ^ item, System::Windows::Controls::ItemsControl ^ parentItemsControl);
public virtual System.Windows.DataTemplate SelectTemplate (object item, System.Windows.Controls.ItemsControl parentItemsControl);
abstract member SelectTemplate : obj * System.Windows.Controls.ItemsControl -> System.Windows.DataTemplate
override this.SelectTemplate : obj * System.Windows.Controls.ItemsControl -> System.Windows.DataTemplate
Public Overridable Function SelectTemplate (item As Object, parentItemsControl As ItemsControl) As DataTemplate
Parameters
- item
- Object
The object for which to select the template.
- parentItemsControl
- ItemsControl
The container for the items.
Returns
The template. The default implementation returns null
.
Applies to
Collaborer avec nous sur GitHub
La source de ce contenu se trouve sur GitHub, où vous pouvez également créer et examiner les problèmes et les demandes de tirage. Pour plus d’informations, consultez notre guide du contributeur.