Windows apps
Collapse the table of content
Expand the table of content
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

IEnumSTATPROPSTG interface

The IEnumSTATPROPSTG interface iterates through an array of STATPROPSTG structures. The STATPROPSTG structures contain statistical data about properties in a property set. IEnumSTATPROPSTG has the same methods as all enumerator interfaces: Next, Skip, Reset, and Clone.

The implementation defines the order in which the properties in the set are enumerated. Properties that are present when the enumerator is created, and are not removed during the enumeration, will be enumerated only once. Properties added or deleted while the enumeration is in progress may or may not be enumerated, but will never be enumerated more than once.

Reserved property identifiers, properties with a property ID of 0 (dictionary), 1 (code page indicator), or greater than or equal to 0x80000000 are not enumerated.

Enumeration of a nonsimple property does not necessarily indicate that the property can be read successfully through a call to IPropertyStorage::ReadMultiple. This is because the performance overhead of checking existence of the indirect stream or storage is prohibitive during property enumeration.

When to implement

Implement IEnumSTATPROPSTG to enumerate the properties within a property set. If using the compound file implementation of the storage object, a pointer to which is available through a call to StgCreateDocfile, you can query for a pointer to IPropertySetStorage. After calling one of its methods either to open or create a property set, you can get a pointer to IEnumSTATPROPSTG with a call to IPropertyStorage::Enum. If performing a custom implementation of IPropertyStorage, implement IEnumSTATPROPSTG to fill a caller-allocated array of STATPROPSTG structures. Each STATPROPSTG structure contains data about a simple property.

When to use

Applications that support storage objects, and persistent properties within those objects, call IPropertyStorage::Enum to return a pointer to IEnumSTATPROPSTG to enumerate the properties in the current property set.


The IEnumSTATPROPSTG interface inherits from the IUnknown interface. IEnumSTATPROPSTG also has these types of members:


The IEnumSTATPROPSTG interface has these methods.


Creates a new enumerator that contains the same enumeration state as the current STATPROPSTG structure enumerator.


Gets a specified number of STATPROPSTG structures.


Resets the enumeration sequence to the beginning of the STATPROPSTG structure array.


Skips a specified number of STATPROPSTG structures in the enumeration sequence.



Minimum supported client

Windows 2000 Professional [desktop apps | UWP apps]

Minimum supported server

Windows 2000 Server [desktop apps | UWP apps]










IID_IEnumSTATPROPSTG is defined as 00000139-0000-0000-C000-000000000046

See also

EnumAll Sample



© 2018 Microsoft