The CopyTo method copies the current Starter GPO and returns a pointer to the copy of the Starter GPO. The method copies all the contents of the Starter GPO but creates the new Starter GPO with the default new Starter GPO delegation settings. Copying a system Starter GPO creates a new custom Starter GPO.
HRESULT CopyTo( VARIANT *pvarNewDisplayName, VARIANT *pvarGPMProgress, VARIANT *pvarGPMCancel, IGPMResult **ppIGPMResult );
Display name to be put on the copied Starter GPO. A display name is assigned if the VARIANT structure does not contain a BSTR, or if pvarNewDisplayName is NULL.
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.
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.
Returns S_OK if successful. Returns a failure code if an error occurs.
For more information, see the following Remarks section.
Note that you must check the code returned by the IGPMResult::OverallStatus method as well as the one returned by this method to determine whether or not the operation succeeded. OverallStatus returns an overall status code for the operation. If no error occurred during the operation, it returns a success code; otherwise it returns a failure code.
|Windows version||Windows Vista Windows Server 2008|