
30
Example call
:
SetDisplayDateTime(TRUE);
Includes
:
#include
“
UserLib.h
"
Description
:
The
SetDisplayDateTime
function will show Time and Date on the
bottom of display and start or close by
bShow
setting.
◆
File Manipulation
_fclose
Purpose
:
Use
_fclose
to close a file opened earlier for buffered input/output
using
_fopen
.
Syntax
:
int _fclose(_TFILE *file_pointer);
Example call
:
_fclose(infile);
Includes
:
#include
“
UserLib.h
"
Description
:
The
_fclose
function closes the file specified by the argument
file_pointer
. This pointer must have been one returned earlier when
the file was opened by
_fopen
. If the file is opened for writing, the
contens of the buffer associated with the file are flushed before the
file is closed. The buffer is then released.
Returns
:
If the file is successfully closed,
_fclose
returns a zero. In case of an
error, the return value is equal to the constant EOF.
_fcloseAll
Purpose
:
Use
_fcloseAll
to close all files opened for buffered input/output with
_fopen
or
tmpfile
.
Syntax
:
void _fcloseAll(void);
Example call
:
_fcloseAll();
Includes
:
#include
“
UserLib.h
"
Description
:
The
_fcloseAll
function closes all files that have been opened by
_fopen
or
tmpfile
for buffered I/O. Buffers associated with files
opened for writing are written out to the corresponding file before
closing.
_filelength
Purpose
:
Use
_filelength
to dertimine the length of a file in bytes.
Syntax
:
size_t _filelength(_TFILE* file_pointer);
Example call
:
file_size = _filelength(infile);
Includes
:
#include
“
UserLib.h
"
Description
:
The
_filelength
function returns the size in number of bytes of the file
specified in the argument
file_pointer
. This pointer should be the
return value of earlier opened file by
_fopen
.
Returns
:
The integer value returned by
_filelength
is the size of the file in
Содержание PT-10
Страница 4: ...3 Keyboard Wedge 99 System 101 Power 102 Other 102 ...
Страница 13: ...12 6 Development Flow Chart ...
Страница 53: ...52 Returns No returns Notes ...