IA4HierarchyFolder::ItemAt

Purpose

Returns as SHITEMID (item identifier) structure for the folder object at the specified position in the list of folder contents. This is a required member function.

Syntax

HRESULT STDMETHODCALLTYPE ItemAt(
    ULONG ulIndex,
    LPITEMIDLIST* ppidl
    ); 

Parameters

ulIndex
The zero-based index of the item for which an item identifier is requested.
ppidl
Address of the pointer that will receive the requested item identifier.

Return Codes

Returns NOERROR if successful or E_FAIL if the item is not available. Returns E_OUTOFMEMORY if insufficient memory was available for the item identifier.

Comments

The iSeries™ Navigator repeatedly calls this function to populate a folder in realtime. Long running operations should therefore be avoided. Refer to CWBA4HYF.H for the format of iSeries Navigator item identifiers. Use the Windows® IMalloc interface to allocate memory for the item identifier.