Gets the name of the next column in the search result that contains data.
HRESULT GetNextColumnName(
ADS_SEARCH_HANDLE hSearchResult, //Search result handle
LPWSTR * ppszColumnName //Name of next column with data
);
This method returns the standard values E_INVALIDARG, E_OUTOFMEMORY, E_UNEXPECTED, and E_FAIL, as well as the following:
The caller is responsible for freeing the memory allocated for the column name.
Using Directory Service Queries