ICertView2 interface

The ICertView2 interface is one of two interfaces that allow properly authorized clients to create a customized or complete view of the Certificate Services database.

The ICertView2 interface is used to perform the following tasks:

  • Establish a connection with a Certificate Services server.
  • Obtain a row-enumeration sequence of the rows in the Certificate Services database.
  • Obtain a column-enumeration sequence for the schema in the Certificate Services database.
  • Get the column count and index.
  • Specify sorting and qualifying restrictions for a column.
  • Specify the number of columns and a specific column in a customized view.
  • Specify which tables are used by subsequent calls to ICertView2 methods (introduced by ICertView2).

In C++, the ICertView2 interface is instantiated through a call to the COM function CoCreateInstance. If, on the other hand, you are using Visual Basic Scripting Edition, you will need to reference the CertAdm Type library in your project and then instantiate the CCertView object by a call to 'New'. The sample code for the OpenConnection method illustrates the instantiation techniques.

The ICertView2 interface is defined in Certview.h. When you create your program, however, use Certsrv.h as the include file. Certadm.dll provides the ICertView2 interface. The type information for this interface is also in Certadml.dll, which is shipped with the Platform Software Development Kit (SDK).

Certificate Services interfaces support both apartment-threading and free-threading models. For better throughput, free threading is recommended.


The ICertView2 interface inherits and extends the ICertView interface.


The ICertView2 interface inherits from ICertView and IDispatch. ICertView2 also has these types of members:


The ICertView2 interface has these methods.


Obtains a pointer to IEnumCERTVIEWCOLUMN for schema enumeration.

(Inherited from ICertView CCertView)

Retrieves the count of columns in the view.

(Inherited from ICertView CCertView)

Retrieves the zero-based index of a named column.

(Inherited from ICertView CCertView)

Establishes an instance of a column-enumeration sequence for the database schema.

(Inherited from ICertView CCertView)

Opens a view to a Certificate Services database and instantiates an instance of an IEnumCERTVIEWROW object.

(Inherited from ICertView CCertView)

Sets sorting and qualifying restrictions on a column.

(Inherited from ICertView CCertView)

Specifies a column for the result set of a customized view of the Certificate Services database.

(Inherited from ICertView CCertView)

Specifies the maximum the number of columns for the result set of a customized view of the Certificate Services database.

(Inherited from ICertView CCertView)

Specifies which Certificate Services database table is used for subsequent calls to the methods of the ICertView2 interface.

(Inherited from ICertView2CCertView)



Minimum supported client

None supported

Minimum supported server

Windows Server 2003 [desktop apps only]


Certview.h (include Certsrv.h)






IID_ICertView2 is defined as d594b282-8851-4b61-9c66-3edadf848863