Compartilhar via


ExtensionMethods.FindCommonAncestor Method (DependencyObject, DependencyObject)

Microsoft internal use only.

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

Syntax

'Declaration
<ExtensionAttribute> _
Public Shared Function FindCommonAncestor ( _
    obj1 As DependencyObject, _
    obj2 As DependencyObject _
) As DependencyObject
public static DependencyObject FindCommonAncestor(
    this DependencyObject obj1,
    DependencyObject obj2
)
[ExtensionAttribute]
public:
static DependencyObject^ FindCommonAncestor(
    DependencyObject^ obj1, 
    DependencyObject^ obj2
)
static member FindCommonAncestor : 
        obj1:DependencyObject * 
        obj2:DependencyObject -> DependencyObject
public static function FindCommonAncestor(
    obj1 : DependencyObject, 
    obj2 : DependencyObject
) : DependencyObject

Parameters

  • obj1
    Type: DependencyObject

    The first object.

  • obj2
    Type: DependencyObject

    The second object.

Return Value

Type: DependencyObject

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).

.NET Framework Security

See Also

Reference

ExtensionMethods Class

FindCommonAncestor Overload

Microsoft.VisualStudio.PlatformUI Namespace