
80
listed below.
fErrorCode
:
2:File handle is NULL.
7:fd is not a file handle of a previously opened file.
_remove
Purpose
:
Delete file.
Syntax
:
int _remove(char *filename);
Example call
:
if (_remove(C:\\data\\store.dat) _puts(“store.dat deleted”);
Includes
:
#include “LIB_CL.h ”
Description
:
Delete the file specified by filename. If filename exceeds 8
characters, it will be truncated to 8 characters long. If the file to be
deleted is a DBF file, the DBF file and all the index (key)
files associated to it will be deleted altogether.
Returns
:
If remove deletes the file successfully, it returns an integer value
of 1. In case of error, remove will return an integer value of 0 and
an error code is set to the global variable fErrorCode to indicate
the error condition encountered. Possible error codes and their
interpretations are listed below.
fErrorCode
:
1:filename is a NULL string.
2:File specified by filename does not exist.
_rename
Purpose
:
Change file name of an existing file.
Syntax
:
int _rename(char *old_filename, char *new_filename);
Example call
:
if (_rename(“C:\\data\\store.dat”,” C:\\data\\text.dat”)
_puts(“store.dat renamed”);
Includes
:
#include “LIB_CL.h ”
Description
:
Change the file name of the file specified by old_filename to
new_filename. But the route does not change.
Returns
:
If rename successfully changes the file name, it returns an integer
value of 1. In case of error, rename will return an integer value of
0, and an error code is set to the global variable fErrorCode to
indicate the error condition encountered. Possible error codes and
their interpretation are listed below.
fErrorCode
:
1:Either old_filename or new_filename is a NULL string.
2:File specified by old_filename does not exist.
3:A file with file name new_filename already exists.
4:File path is error
5:Filename is too long.
6:File is using.
Содержание 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 ...