Partager via


IAccPropServices::ClearProps

Servers use ClearProps to restore default values to properties of accessible elements that they had previously annotated.

If servers know the HWND of the object they want to clear, they can use IAccPropServices::ClearHwndProps.

HRESULT ClearProps (
  const BYTE* pIDString,  DWORD dwIDStringLen,  const MSAAPROPID* paProps,  int cProps);

Parameters

  • pIDString, dwIDStringLen
    [in] Identify the accessible element that is to be un-annotated.
  • paProps, cProps
    [in] Specify an array of properties that is to be reset. These properties will revert to the default behavior they displayed before they were annotated.

Return Values

If successful, returns S_OK, even if the specified properties were never annotated on the accessible object; clearing already cleared properties is considered a success.

Returns E_INVALIDARG if any of the properties in the paProps array are not supported.

May return other error codes under exceptional error conditions such as low memory.

Remarks

See the support section for a list of supported properties and their expected types.

Clearing the annotation for a property will cause any associated resources to be released. If a callback property server was used (see SetPropServer), it will be released.

Requirements

**  Windows NT/2000/XP/Server 2003:** Included in Windows XP and Windows Server 2003.
**  Windows 95/98/Me:** Unsupported.
**  Redistributable:** Requires Active Accessibility 2.0 RDK on Windows NT 4.0 SP6 and Windows 98.
**  Header:** Declared in Oleacc.h; include Initguid.h before including Oleacc.h.