Share via


IMetaDataImport::EnumUserStrings Method

Enumerates String tokens representing hard-coded strings in the current metadata scope.

HRESULT EnumUserStrings (
    HCORENUM    *phEnum,
        mdString    rStrings[],
    ULONG       cMax,
    ULONG       *pcStrings
);

Parameters

Parameter Description

phEnum

[in, out] A pointer to the enumerator. This must be NULL for the first call of this method.

rStrings

[out] The array used to store the String tokens.

cMax

[in] The maximum size of the rStrings array.

pcStrings

[out] The number of String tokens returned in rStrings.

Return Value

HRESULT Description

S_OK

EnumUserStrings returned successfully.

S_FALSE

There are no tokens to enumerate. In that case, pcStrings is zero.

Remarks

The String tokens are created by the IMetaDataEmit::DefineUserString Method method. This method is designed to be used by a metadata browser rather than by a compiler.

Requirements

Platforms: Windows 2000, Windows XP, Windows Server 2003 family

Header: Cor.h

Library: Included as a resource in Mscoree.dll

.NET Framework Version: 2.0, 1.1, 1.0

See Also

Reference

IMetaDataImport Interface
IMetaDataImport2 Interface