AutomationElement::Equality Operator (AutomationElement^, AutomationElement^)


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Returns a value indicating whether the specified AutomationElement objects refer to the same user interface (UI) element.

Namespace:   System.Windows.Automation
Assembly:  UIAutomationClient (in UIAutomationClient.dll)

static bool operator ==(
	AutomationElement^ left,
	AutomationElement^ right

Return Value

Type: System::Boolean

true if the two AutomationElement objects refer to the same UI element; otherwise false.

Two AutomationElement objects that compare as equal might contain different cached information from different points in time. Equality only tests that the objects refer to the same underlying UI element.

.NET Framework
Available since 3.0
Return to top