CreateClassMoniker function (COM)

Switch View :
ScriptFree
CreateClassMoniker function

Applies to: desktop apps | Metro style apps

Creates a class moniker that refers to the specified class.

Syntax

HRESULT CreateClassMoniker(
  __in   REFCLSID rclsid,
  __out  LPMONIKER *ppmk
);

Parameters

rclsid [in]

A reference to the CLSID of the object type to which this moniker binds.

ppmk [out]

The address of an IMoniker* pointer variable that receives the interface pointer to the new class moniker. On successful return, the function has called AddRef on the moniker and the caller is responsible for calling Release. When an error occurs, the value of the moniker pointer is NULL.

Return value

This function can return the following values.

Return codeDescription
S_OK

The moniker has been created successfully.

E_INVALIDARG

One or more arguments are invalid.

 

Remarks

The class moniker will support the binding to a fresh instance of the class identified by the CLSID in rclsid.

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

Objbase.h

Library

Ole32.lib

DLL

Ole32.dll

See also

IMoniker

 

 

Send comments about this topic to Microsoft

Build date: 3/7/2012