IGPMDomain2::LoadStarterGPO method (gpmgmt.h)

Opens a Starter Group Policy object (GPO) cabinet (CAB) file and imports it into the domain.


  [in]            BSTR         bstrLoadFile,
  [in]            VARIANT_BOOL bOverwrite,
  [in, optional]  VARIANT      *pvarGPMProgress,
  [out, optional] VARIANT      *pvarGPMCancel,
  [out]           IGPMResult   **ppIGPMResult


[in] bstrLoadFile

Required. Name of the CAB file to load. Use a null-terminated string.

[in] bOverwrite

Determines whether to overwrite any existing versions of the Starter GPO. Loading a Starter GPO from a CAB retains the ID of the original Starter GPO used to create the CAB, therefore it is possible to have a version of the Starter GPO already existing in the domain when the LoadStarterGPO method is called.


Do not overwrite an existing Starter GPO.


Overwrite an existing Starter GPO.

[in, optional] pvarGPMProgress

Specifies a pointer to an IGPMAsyncProgress interface that allows the client to receive status notifications about the progress of the copy operation. This parameter must be NULL if the client does not receive asynchronous notifications.

[out, optional] pvarGPMCancel

Receives a pointer to an IGPMAsyncCancel interface that the client can use to cancel the copy operation. This parameter is not returned if pvarGPMProgress is NULL.

[out] ppIGPMResult

Address of a pointer to the IGPMResult interface that represents the result of the load operation. That interface contains pointers to an IGPMStarterGPO interface and to an IGPMStatusMsgCollection interface.

Return value


Returns S_OK if successful. Returns a failure code if an error occurs.


Returns a reference to a GPMResult object.


Returns a reference to a GPMResult object.


Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
Target Platform Windows
Header gpmgmt.h
DLL Gpmgmt.dll

See also