Return Values

This topic describes the most common return values, and other return values that you might see less frequently.

Common Return Values

The IAccessible methods return one of the following values, defined in winerror.h, or another standard COM error code:

  • S_OK
    The method succeeded.
  • S_FALSE
    The method succeeded in part. This happens when the method succeeds, but the requested information is not available. For example, Active Accessibility returns S_FALSE if you call IAccessible::accHitTest to retrieve a child object at a given point, and the specified point is not within the object or the object's child.
  • DISP_E_MEMBERNOTFOUND
    The object does not support the requested property or action. For example, a push button returns this value if you request its Value property, since it does not have a Value property.
  • E_NOTIMPL
    The method is not implemented. This value occurs when a client calls a method that is not yet supported in that operating system.
  • E_INVALIDARG
    One or more arguments were invalid. This error occurs when the caller attempts to identify a child object using an identifier that the server does not recognize. This error also results when a client attempts to identify a child object within an object that has no children.
  • E_OUTOFMEMORY
    The method was unable to allocate memory required to complete an operation crucial to its success.
  • E_FAIL
    An unknown or generic error occurred.

Additional Return Values

The following are return values that IAccessible methods might return. These return values are not as common as the previous ones, but you should be aware of them.

  • E_ACCESSDENIED
    This is returned when you call get_accValue to get the value of a password control.

  • DISP_E_EXCEPTION

  • CO_E_DISCONNECTED

See Also

Checking IAccessible Return Values