Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Enumerates MemberDef tokens representing members of the specified type with the specified name.
Syntax
HRESULT EnumMembersWithName(
[in, out] HCORENUM *phEnum,
[in] mdTypeDef tkTypeDef,
[in] LPCWSTR szName,
[out] mdToken [] rgMembers,
[in] ULONG cMax,
[out] ULONG *pcTokens
);
Parameters
[in, out] phEnum
A pointer to the enumerator.
[in] tkTypeDef
A TypeDef token representing the type with members to enumerate.
[in] szName
The member name that limits the scope of the enumerator.
[out] rgMembers
The array used to store the MemberDef tokens.
[in] cMax
The maximum size of the rgMembers array.
[out] pcTokens
The actual number of MemberDef tokens returned in rgMembers.
Return value
HRESULT | Description |
---|---|
S_OK | EnumMembersWithName returned successfully. |
S_FALSE | There are no MemberRef tokens to enumerate. In this case, pcTokens is 0 (zero). |
Remarks
This method enumerates fields and methods, but not properties or events. Unlike EnumMembers, EnumMembersWithName discards all field and member tokens that do not have the specified name.
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | rometadataapi.h |