IUIAutomation::ElementFromIAccessible Method
Retrieves a UI Automation element for the specified accessible object from a Microsoft Active Accessibility server.
Syntax
HRESULT ElementFromIAccessible( IAccessible *accessible, int childId, IUIAutomationElement **element );
Parameters
- accessible
[in] The address of the IAccessible interface of the accessible object.- childId
[in] The child ID of the accessible object.- element
[out, retval] The address of a variable that receives a pointer to the IUIAutomationElement interface of the UI Automation element.
Return Value
Returns S_OK if successful, or an error value otherwise.
Remarks
This method enables UI Automation clients to get IUIAutomationElement interfaces for accessible objects implemented by a Microsoft Active Accessiblity server. This method may fail if the server implements UI Automation provider interfaces alongside Microsoft Active Accessibility support. The method returns E_INVALIDARG if the client passes an OLEACC or UIA-to-MSAA Bridge object in the accessible and childId parameters.
See Also