Writes to disk a file previously opened with create( ) or open( ) without closing the file. Returns true if successful and false if unsuccessful.


<oRef>.flush( )


A reference to the File object that created or opened the file.

Property of



Use flush( ) to save a file in the file buffer to disk, flush the file buffer, and keep the file open. If flush( ) is successful, it returns true.

Flushing a buffer to disk is similar to saving the file and continuing to work on it. Until you flush an open file buffer to disk, any data in the buffer is stored only in RAM (random-access memory). If the power to the computer fails or dBASE Plus ends abnormally, data in RAM is lost. However, if you have used flush( ) to write the file buffer to disk, you lose only data that was added between the time you issued flush( ) and the time the system failed.

To save the file to disk and close the file, use close( ).