cwbSV_ReadPrevRecord
Use the cwbSV_ReadPrevRecord API with this product.
Purpose
Reads the previous record in the service file into the record handle that is provided. Subsequent calls can be made to retrieve the information that is stored in this record (for example, GetProduct(), GetDateStamp(), and so forth).
Syntax
unsigned int CWB_ENTRY cwbSV_ReadPrevRecord(
cwbSV_ServiceFileHandle serviceFileHandle,
cwbSV_ServiceRecHandle serviceRecHandle,
cwbSV_ErrHandle errorHandle);
Parameters
- cwbSV_ServiceFileHandle serviceFileHandle - input
- Handle that was returned by a previous call to the cwbSV_OpenServiceFile function. V_ServiceRecHandle serviceRecHandle -input Handle that was returned by a previous call to the cwbSV_CreateServiceRecHandle function.
- cwbSV_ErrHandle errorHandle - output
- Any returned messages will be written to this object. It is created with the cwbSV_CreateErrHandle API. The messages may be retrieved through the cwbSV_GetErrText API. If the parameter is set to zero, no messages will be retrieved.
Return Codes
The following list shows common return values.
- CWB_OK
- Successful completion.
- CWB_END_OF_FILE
- End of file has been reached.
- CWB_FILE_IO_ERROR
- Record could not be read.
- CWB_INVALID_HANDLE
- Handle is not valid.
Usage
This read would normally be used once the priming read, "ReadNewestRecord()" is performed.