TextBlock.GetVisualChild(Int32) 方法

定义

返回指定索引位置处的 Visual 子项。Returns the Visual child at a specified index.

protected:
 override System::Windows::Media::Visual ^ GetVisualChild(int index);
protected override System.Windows.Media.Visual GetVisualChild (int index);
override this.GetVisualChild : int -> System.Windows.Media.Visual
Protected Overrides Function GetVisualChild (index As Integer) As Visual

参数

index
Int32

一个从零开始的索引,指定要返回的 Visual 子项。A zero-based index specifying the Visual child to return. 该值必须介于 0 和(VisualChildrenCount 减 1)之间。This value must be between 0 and (VisualChildrenCount minus 1)

返回

位于指定索引位置处的 Visual 子项。The Visual child at the specified index.

异常

index 不在 0 和(VisualChildrenCount 减 1)之间。index is not between 0 and (VisualChildrenCount minus 1)

注解

此方法重写 FrameworkElement.GetVisualChildThis method overrides FrameworkElement.GetVisualChild.

适用于