IAccessible::put_accValue method (oleacc.h)

The IAccessible::put_accValue method sets the value of the specified object. Not all objects have a value.


HRESULT put_accValue(
  [in] VARIANT varChild,
  [in] BSTR    szValue


[in] varChild


Specifies whether the value information being set belongs to the object or one of the object's child elements. This parameter is either CHILDID_SELF (to set information on the object) or a child ID (to set information about the object's child element). For more information about initializing the VARIANT structure, see How Child IDs Are Used in Parameters.

[in] szValue

Type: BSTR

A localized string that contains the object's value.

Return value


If successful, returns S_OK.

If not successful, returns one of the values in the table that follows, or another standard COM error code. Servers return these values, but clients must always check output parameters to ensure that they contain valid values. For more information, see Checking IAccessible Return Values.

Error Description
The object does not support this property.
An argument is not valid.


The IAccessible::put_accValue method is supported for some UI elements (usually edit controls). For UI elements that do not support this method, control-specific methods are used instead. For more information, see Supported User Interface Element Reference.


Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header oleacc.h
Library Oleacc.lib
DLL Oleacc.dll
Redistributable Active Accessibility 1.3 RDK on Windows NT 4.0 with SP6 and later and Windows 95