ICertServerExit::EnumerateExtensionsSetup method

The EnumerateExtensionsSetup method initializes the internal enumeration pointer to the first certificate extension associated with the current context.

The enumeration process enumerates certificate extensions recorded in the database, even those that are disabled and do not appear in the certificate.

Syntax


HRESULT EnumerateExtensionsSetup(
  [in] LONG Flags
);

Parameters

Flags [in]

This parameter is reserved and must be set to zero.

Return value

VB

If the method succeeds, the method returns S_OK.

If the method fails, it returns an HRESULT value that indicates the error. For a list of common error codes, see Common HRESULT Values.

Remarks

You must call ICertServerExit::SetContext before using this method.

Examples


// Set the context. The value nContext (long) would be the same
// as the context parameter in ICertExit::Notify.
// hr is defined as an HRESULT.
hr = pCertServerExit->SetContext( nContext );
if (FAILED(hr))
{
    printf("Failed SetContext [%x]\n", hr);
    goto error;
}

// Setup the enumeration.
hr = pCertServerExit->EnumerateExtensionsSetup( 0 );
if (FAILED(hr))
{
    printf("Failed EnumerateExtensionsSetup [%x]\n", hr);
    goto error;
}

Requirements

Minimum supported client

None supported

Minimum supported server

Windows Server 2003 [desktop apps only]

Header

Certif.h (include Certsrv.h)

Library

Certidl.lib

DLL

Certcli.dll

IID

IID_ICertServerExit is defined as 4BA9EB90-732C-11D0-8816-00A0C903B83C

See also

ICertServerExit
ICertServerExit::EnumerateExtensions
ICertServerExit::EnumerateExtensionsClose

 

 

Show: