
27
Purpose
:
Use
SearchRowOfLookupFile
to search the data matching to index
field in the index files.
Syntax
:
Char *SearchRowOfLookupFile(char *pssLookupFile, int
nLookupFileSize, int ulStartByte, int nIndexLen, char *pssData, int
nDataLen);
Example call
:
pssSearchData = SearchRowOfLookupFile(pssLookupFile,
unLookupFileSize, 0, 10, acMealOrdered, strlen(acMealOrdered));
Includes
:
#include
“
UserLib.h
"
Description
:
The
SearchRowOfLookupFile
function will search, according to the
continuous address of disk specified by
passData
in the
passLookupFile
and the continuous space length
nLookupFileSize
,
the index fields which are matching with
pssData
and return the first
character address of the data line so that user can make further record
line field data processing. The
ulStartByte
will define the index field
to the starting byte address of each record line.
nIndexLen
will
determine the data length of index field, and also the same data
length of
pssData
correspondent to the index field as well. When the
data length
nDataLen
of
passData
is less than the index field data
length
nIndexLen
, a Null will be returned to express that there is no
data field was corresponded.
Returns
:
If the data is found, the
SearchRowOfLookupFile
function returns the
first character address of the data line. If it fails to search the data, it
returns NULL.
Comments
:
Note that the index file is placed under D:\Lookup directory in the
virtual disk.
◆
Date and Time Function
GetDateTimeFormat
Purpose
:
Use
GetDateTimeFormat
to get different format of date and time
from RTC.
Syntax
:
int GetDateTimeFormat(char *pssBuffer, int nType);
Example call
:
char accTemp[20]; GetDateTimeFormat(accTemp, 34);
Includes
:
#include
“
UserLib.h
"
Description
:
The
GetDateTimeFormat
function will output different format of
time and date as shown below, according to the input of different
nType
. The size of buffer should be larger than 20Bytes.
Содержание 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 ...