ItemContainerGenerator.ContainerFromIndex(Int32) 方法

定义

注意

ContainerFromIndex 可能会在Windows 8.1后更改或不可用。 请改用 ItemsControl.ContainerFromIndex

返回 ItemCollection 中指定索引处的项的容器。

public:
 virtual DependencyObject ^ ContainerFromIndex(int index) = ContainerFromIndex;
/// [Windows.Foundation.Metadata.Deprecated("ContainerFromIndex may be altered or unavailable for releases after Windows 8.1. Instead, use ItemsControl.ContainerFromIndex.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Microsoft.UI.Xaml.WinUIContract")]
DependencyObject ContainerFromIndex(int const& index);
[Windows.Foundation.Metadata.Deprecated("ContainerFromIndex may be altered or unavailable for releases after Windows 8.1. Instead, use ItemsControl.ContainerFromIndex.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Microsoft.UI.Xaml.WinUIContract")]
public DependencyObject ContainerFromIndex(int index);
function containerFromIndex(index)
Public Function ContainerFromIndex (index As Integer) As DependencyObject

参数

index
Int32

int

要检索的项的索引。

返回

项集合中位于指定索引处的项的容器(如果该项具有容器);否则为 null。

属性

适用于