共用方式為


Visual.IsAncestorOf(DependencyObject) 方法

定義

判斷視覺物件是否為子系視覺物件的祖系。

public:
 bool IsAncestorOf(System::Windows::DependencyObject ^ descendant);
public bool IsAncestorOf (System.Windows.DependencyObject descendant);
member this.IsAncestorOf : System.Windows.DependencyObject -> bool
Public Function IsAncestorOf (descendant As DependencyObject) As Boolean

參數

descendant
DependencyObject

型別 DependencyObject 的值。

傳回

Boolean

如果視覺物件是 descendant 的祖系則為 true,否則為 false

適用於