ITextRangeProvider::GetEnclosingElement method
Returns the innermost element that encloses the text range.
Syntax
HRESULT GetEnclosingElement( [out, retval] IRawElementProviderSimple **pRetVal );
Parameters
- pRetVal [out, retval]
-
Type: IRawElementProviderSimple**
Receives a pointer to the UI Automation provider of the enclosing element. This parameter is passed uninitialized.
Return value
Type: HRESULT
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
The enclosing element is typically the text provider that supplies the text range. However, if the text provider supports child elements such as tables or hyperlinks, the enclosing element could be a descendant of the text provider.
Requirements
|
Minimum supported client |
Windows XP [desktop apps | Windows Store apps] |
|---|---|
|
Minimum supported server |
Windows Server 2003 [desktop apps | Windows Store apps] |
|
Header |
|
|
IDL |
|
See also
- Reference
- ITextProvider
- ITextRangeProvider
- Conceptual
- UI Automation Providers Overview