Share via


ItemsRepeater.ItemTemplate Property

Definition

Gets or sets the template used to display each item.

public:
 property Platform::Object ^ ItemTemplate { Platform::Object ^ get(); void set(Platform::Object ^ value); };
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
IInspectable ItemTemplate();

void ItemTemplate(IInspectable value);
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
IInspectable ItemTemplate();

void ItemTemplate(IInspectable value);
public object ItemTemplate { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] set; }
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
public object ItemTemplate { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] set; }
var object = itemsRepeater.itemTemplate;
itemsRepeater.itemTemplate = object;
Public Property ItemTemplate As Object

Property Value

Object

Platform::Object

IInspectable

The template that specifies the visualization of the data objects. The default is null.

Attributes
Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallbackAttribute

Remarks

Set this property to a factory object used to generate a UIElement for a given data item. This can be a DataTemplate, a DataTemplateSelector, or a custom implementation of IElementFactory IElementFactory that creates UIElements by some other mechanism.

Generated elements might be re-used. For example, an element generated to display the item at index 0 might be reused later to display the item at index 100.

Applies to