CSystemClock::CreateInstance

Creates a new instance when placed in the factory template table.

static CUnknown * WINAPI CreateInstance(
LPUNKNOWN pUnk,
HRESULT *phr );

Parameters

  • pUnk
    Pointer to LPUNKNOWN.
  • phr
    Pointer to an HRESULT value in which to return resulting information.

Return Values

Returns a pointer to a new Component Object Model (COM) object.

Remarks

This member function is required to create objects using the class factory. It calls the class constructor.

The phr parameter will be modified only if a failure occurs. If it is a failure code on input, construction can be terminated, but in any case the destructor will be called by the creator when the HRESULT error is detected.

 Last updated on Tuesday, July 13, 2004

© 1992-2000 Microsoft Corporation. All rights reserved.