ItemContainerGenerator.ContainerFromIndex(Int32) 方法

定義

注意

Windows 8.1 之後,可能會變更或無法使用 ContainerFromIndex。 請改用 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。

屬性

適用於