3.9.4.10 ITypeInfo2::GetDocumentation2 (Opnum 31)

The GetDocumentation2 method retrieves values associated with a type member.

 HRESULT GetDocumentation2(
   [in] MEMBERID memid,
   [in] LCID lcid,
   [in] DWORD refPtrFlags,
   [out] BSTR* pbstrHelpString,
   [out] DWORD* pdwHelpStringContext,
   [out] BSTR* pbstrHelpStringDll
 );

memid: MUST be the MEMBERID of a member of the type (as specified in section 2.2.35), or MEMBERID_NIL.

If memid is MEMBERID_NIL, the values of pBstrHelpString, pdwHelpStringContext, and pBstrHelpStringDll MUST correspond to the attributes declared with the type as specified in 2.2.49.3. Otherwise, they MUST correspond to the attributes declared with the specified member of the type.

lcid: MUST be the Locale ID associated with the specified type member.

refPtrFlags: MUST be 0, or a combination of the bit flags specified in the following table.

Value

Meaning

TYPEINFO_HelpStringArg

0x00000001

MUST specify that the client is interested in the actual pBstrHelpString [out] argument.

TYPEINFO_HelpStringContextArg

0x00000002

MUST specify that the client is interested in the actual pdwHelpStringContext [out] argument.

TYPEINFO_HelpStringDllArg

0x00000004

MUST specify that the client is interested in the actual pBstrHelpStringDll [out] argument.

pbstrHelpString: If the TYPEINFO_HelpStringContextArg and TYPEINFO_HelpStringDllArg bit flags are set in refPtrFlags, pbstrHelpString MUST be set to an implementation-specific BSTR<60> . Otherwise, MUST be set to a NULL BSTR.

pdwHelpStringContext: MUST be set to the value that was associated with the specified type or type member using the [helpstringcontext] attribute (see IDL Automation Scope) if the TYPEINFO_HelpStringContextArg bit flag is set in refPtrFlags. MUST be set to 0 otherwise.

pbstrHelpStringDll: MUST be set to the documentation string that was associated with the specified type or type member using the [helpstringdll] attribute (see IDL Automation Scope) if the TYPEINFO_HelpStringDllArg bit flag is set in refPtrFlags. MUST be set to a NULL BSTR otherwise.

Return Values: The method MUST return information in an HRESULT data structure, defined in [MS-ERREF] section 2.1. The severity bit in the structure identifies the following conditions:

  • If the severity bit is set to 0, the method completed successfully.

  • If the severity bit is set to 1, the method failed and encountered a fatal error.