ItemContainerStyle property

ItemsControl.ItemContainerStyle property

Gets or sets the style that is used when rendering the item containers.

Syntax


Public Property ItemContainerStyle As Style


<itemsControl>
  <itemsControl.ItemContainerStyle>
    inlineStyle
  </itemsControl.ItemContainerStyle>
</itemsControl>


<itemsControl ItemContainerStyle="resourceReferenceToStyle"/>

XAML Values

inlineStyle

A single Style object element. That Style would typically have multiple setters that set properties on the item container type being targeted. (For ListBox, that type is ListBoxItem.)

resourceReferenceToStyle

A {StaticResource} markup extension reference to an existing Style from a XAML resource dictionary.

Property value

Type: Style

The style applied to the item containers. The default is null.

Requirements (Windows 10 device family)

Device family

Universal, introduced version 10.0.10240.0

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.UI.Xaml.Controls
Windows::UI::Xaml::Controls [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.UI.Xaml.Controls
Windows::UI::Xaml::Controls [C++]

Metadata

Windows.winmd

See also

ItemsControl

 

 

Show:
© 2016 Microsoft