ExtensionMethods::FindAncestorOrSelf<TAncestorType> Method (DependencyObject)

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Namespace:  Microsoft.VisualStudio.PlatformUI
Assembly:  Microsoft.VisualStudio.Shell.10.0 (in Microsoft.VisualStudio.Shell.10.0.dll)

[ExtensionAttribute]
public:
generic<typename TAncestorType>
where TAncestorType : DependencyObject 
static TAncestorType FindAncestorOrSelf(
	DependencyObject^ obj
)

Type Parameters

TAncestorType

Return Value

Type: TAncestorType

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type DependencyObject. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

Show: