This method of the IPersistStorage interface saves an object, and any nested objects that it contains, into the specified storage. The object is placed in NoScribble mode, and it must not write to the specified storage until it receives a call to its IPersistStorage.SaveCompleted method.
public void Save(IStorage pStgSave, boolean fSameAsLoad);
S_OK -- The object was successfully saved.
STG_E_MEDIUMFULL -- The object was not saved because of a lack of space on the disk.
E_FAIL -- The object could not be saved due to errors other than a lack of disk space.
[in] pStgSave | The IStorage pointer to the storage into which the object is to be saved. |
[in] fSameAsLoad | Indicates whether the specified storage is the current one, which was passed to the object by one of the following calls:
This parameter is set to FALSE when performing a Save As or Save A Copy To operation or when performing a full save. In the latter case, this method saves to a temporary file, deletes the original file, and renames the temporary file. This parameter is set to TRUE to perform a full save in a low-memory situation or to perform a fast incremental save in which only the dirty components are saved. |