User Tools

Site Tools


flushing_20file_20buffers

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

flushing_20file_20buffers [2018/03/31 13:19]
127.0.0.1 external edit
flushing_20file_20buffers [2018/04/17 16:17] (current)
tbest3112 Added syntax highlighting
Line 6: Line 6:
   - If the file you are creating is shared between two processes (e.g. one program writing to the file and another program reading from the file) it is necessary to flush the buffers to ensure that all the data written by one program can be read by the other program.   - If the file you are creating is shared between two processes (e.g. one program writing to the file and another program reading from the file) it is necessary to flush the buffers to ensure that all the data written by one program can be read by the other program.
 \\  In both cases flushing BBC BASIC'​s file buffer is simply a case of issuing the following statement:​\\ ​ \\  In both cases flushing BBC BASIC'​s file buffer is simply a case of issuing the following statement:​\\ ​
 +<code bb4w>
         PTR#chan% = PTR#chan%         PTR#chan% = PTR#chan%
 +</​code>​
 where **chan%** is the channel number returned by [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openin|OPENIN]],​ [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openout|OPENOUT]] or [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openup|OPENUP]]. where **chan%** is the channel number returned by [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openin|OPENIN]],​ [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openout|OPENOUT]] or [[http://​www.bbcbasic.co.uk/​bbcwin/​manual/​bbcwin6.html#​openup|OPENUP]].
flushing_20file_20buffers.txt ยท Last modified: 2018/04/17 16:17 by tbest3112