HrESERestoreClose Function

Topic Last Modified: 2006-06-12

The HrESERestoreClose function informs the Exchange Storage Engine (ESE) that the files have been completely restored from the backup storage media. This does not instruct the ESE to begin recovery.

Applies To

ESEbcli2 DLL Functions Interface

Syntax

HRESULT HrESERestoreClose
(
        HCCX phccxRestoreContext,
        unsigned long fRestoreAbort
);

Parameters

  • phccxRestoreContext
    Input parameter. A handle to a restore context. The handle is passed to the various restore functions, and contains information about the current restore operations.
  • fRestoreAbort
    Input parameter. Flag indicating the reason for closing the restore operation. The only recognized values are: RESTORE_CLOSE_NORMAL (0x0) AND RESTORE_CLOSE_ABORT (0x1).

Return Value

The following return codes can be returned. To retrieve the error string for an ESE error, use the standard FormatMessage function. For the general errors hrErrorFromESECall and hrErrorFromCallbackCall, more information about the error is available using the standard GetLastError function.

S_OK

Success.

ESE-specific error codes

ESE-specific error codes, as defined in esebkmsg.h.

Other

Other Microsoft® Win32® or remote procedure call (RPC) errors.

Remarks

This function does not begin the database recovery operation. The application must call HrESERestoreComplete to begin the database recovery operation.

If the fRestoreAbort parameter is passed as RESTORE_CLOSE_ABORT (0x1), then the restore operation is aborted. The application should not attempt to recover the database if the restore did not complete correctly.

Applications that use this function must be run under a user account that has Microsoft Windows® server operating systems Backup and Restore privileges.