[This is preliminary documentation and subject to change.]
Performs the object's default action.
HRESULT accDoDefaultAction(
VARIANT varChild
);
Returns S_OK if successful or one of the following values or a standard COM error code otherwise.
DISP_E_MEMBERNOTFOUND |
E_INVALIDARG |
You can retrieve the object's DefaultAction property by using the IAccessible::get_accDefaultAction method.
Only controls that perform actions support IAccessible::accDoDefaultAction. Some controls, like edit fields, can have a primary value but not a primary action.
In most cases, the client could also perform this action using standard OLE Automation, as well as carry out any nondefault actions supported by the object. However, this method provides an easy way to identify and perform an object's most commonly used function. Also, with the information provided by the IAccessible::get_accDefaultAction method, you can describe the action to the user even if the application does not ship an OLE Automation type library.