Platform SDK: Active Directory, ADSI, and Directory Services |
The IDirectorySearch::FreeColumn method releases memory that the IDirectorySearch::GetColumn method allocated for data for the column.
HRESULT FreeColumn( PADS_SEARCH_COLUMN pSearchColumn );
This method returns the standard return values, as well as the following:
For other return values, see ADSI Error Codes.
ADS_SEARCH_COLUMN col; /*.. omit set preference and execute … */ while( m_pSearch->GetNextRow( hSearch) != S_ADS_NOMORE_ROWS ) { // Get the Name and display it in the list. hr = m_pSearch->GetColumn( hSearch, pszAttr[0], &col ); if ( SUCCEEDED(hr) ) { printf("%S\n", col.pADsValues->CaseIgnoreString); m_pSearch->FreeColumn( &col ); } } m_pSearch->CloseSearchHandle( hSearch );
Windows NT/2000: Requires Windows 2000 (or Windows NT 4.0 with DSClient).
Windows 95/98: Requires Windows 95 or later (with DSClient).
Header: Declared in Iads.h.
IDirectorySearch, IDirectorySearch::GetColumn, ADSI Error Codes