Index   Commented   Search   About

ILockBytes::Flush

Ensures that any internal buffers maintained by the ILockBytes implementation are written out to the backing storage.

HRESULT Flush(void);

Return Values

S_OK

The flush operation was successful.

STG_E_ACCESSDENIED

The caller does not have permission to access the byte array.

STG_E_MEDIUMFULL

The flush operation is not completed because there is no space left on the storage device.

E_FAIL

General failure writing data.

STG_E_TOOMANYFILESOPEN

Under certain circumstances, Flush does a dump-and-close to flush. This can lead to STG_E_TOOMANYFILESOPEN if there are no file handles available.

STG_E_INVALIDHANDLE

An invalid floppy change has been made.

Comments

This method flushes internal buffers to the underlying storage device.

The OLE-provided implementation of compound files uses this method during a transacted commit operation to provide a two-phase commit process that protects against loss of data.

See Also

IStorage::Commit

Related Links

Software for Delphi and C++ Builder developers
Software for Visual Studio .NET developers
Software for Visual Basic 6 developers
Delphi Tips&Tricks
MegaDetailed.NET
TMS Scripter Studio Pro components for Delphi/C++Builder

More Online Helps

Win32 Programmer's Reference (win32.hlp)
Win32 Multimedia Programmer's Reference (mmedia.hlp)
Microsoft Windows Pen API Programmer's Reference (penapi.hlp)
Microsoft Windows Sockets 2 Reference (sock2.hlp)
Microsoft Windows Telephony API (TAPI) Programmer's Reference (sock2.hlp)
Unix Manual Pages

Free Tech Secrets ;) Copyright © 2008 Free Tect Secrets ;) greatis just4fun network just4fun