Closes a data set opened by NWSMTSOpenDataSetForBackup or NWSMTSOpenDataSetForRestore.
#include <smstsapi.h> CCODE NWSMTSCloseDataSet ( UINT32 connection, UINT32 *dataSetHandle);
(IN) Specifies the connection information returned by NWSMTSConnectToTargetService or NWSMTSConnectToTargetServicEx.
(IN/OUT) Points to the address of the data set handle returned by NWSMTSOpenDataSetForBackup or NWSMTSOpenDataSetForRestore.
See Section 9.3, Target Service Return Values for more information.
The following table lists the return values associated with the function.
Upon return, NWSMTSCloseDataSet sets dataSetHandle to zero. If parent handles are used and the parent's subordinates are being restored, the engine should not call NWSMTSCloseDataSet until all subordinates are restored.
NWSMTSCloseDataSet restores all of the data set's original attributes to what they were before the data set was opened for backup (except its archive information). To set the data set's archive status, the engine should call NWSMTSSetArchiveStatus before closing the data set.
Between the time NWSMTSOpenDataSetForBackup and NWSMTSCloseDataSet are called, the TSA ensures that the data set's attributes are not altered.
See NWSMTSOpenDataSetForRestore for an example.