ITextRangeProvider.GetEnclosingElement Method

Returns the innermost element that encloses the text range.

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

IRawElementProviderSimple GetEnclosingElement()

Return Value

Type: System.Windows.Automation.Provider.IRawElementProviderSimple
The enclosing control, typically the text provider that provides the text range. However, if the text provider supports child text elements such as tables or hyperlinks, the enclosing element can be a descendant of the text provider.


Supported in: 5, 4

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions