Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic


Flushes any data remaining in the buffer, closes the archive, and disconnects the archive from the file.

void Close( );

No further operations on the archive are permitted. After you close an archive, you can create another archive for the same file or you can close the file.

The member function Close ensures that all data is transferred from the archive to the file, and it makes the archive unavailable. To complete the transfer from the file to the storage medium, you must first use CFile::Close and then destroy the CFile object.

See the example for CArchive::WriteString.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2014 Microsoft. All rights reserved.