Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This method retrieves a pointer to an enumerator object that can be used to enumerate the storage and stream objects contained within this storage object.

Syntax

HRESULT EnumElement( 
  DWORD 
reserved1, 
  void* 
reserved2, 
  DWORD 
reserved3, 
  IEnumSTATSTG** 
ppenum 
);

Parameters

reserved1

[in] Reserved for future use; set to zero.

reserved2

[in] Reserved for future use; set to NULL.

reserved3

[in] Reserved for future use; set to zero.

ppenum

[out] Address of IEnumSTATSTG* pointer variable that receives the interface pointer to the new enumerator object.

Return Value

The following table shows the return values for this method.

Value Description

S_OK

The enumerator object was successfully returned.

E_PENDING

Asynchronous Storage only: Part or all of the element's data is currently unavailable.

For more information see the IFillLockBytesinterface and Asynchronous Storage.

STG_E_INSUFFICIENTMEMORY

The enumerator object could not be created due to lack of memory.

STG_E_INVALIDPARAMETER

One of the parameters was not valid.

STG_E_REVERTED

The storage object has been invalidated by a revert operation above it in the transaction tree.

Remarks

The enumerator object returned by this method implements the IEnumSTATSTGinterface, one of the standard enumerator interfaces that contain the Next, Reset, Clone, and Skipmethods.

IEnumSTATSTGenumerates the data stored in an array of STATSTGstructures.

The storage object must be open in read mode to allow the enumeration of its elements.

The order in which the elements are enumerated and whether the enumerator is a snapshot or always reflects the current state of the storage object, and depends on the IStorageinterface implementation.

To determine whether the platform supports this interface, see Determining Supported COM APIs.

Requirements

Header objidl.h, objidl.idl
Library ole32.lib, uuid.lib
Windows Embedded CE Windows CE 2.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also