unsigned int numrec (FCB *fcb, const char *fn);

Get the number of records in a file. The file should be closed (or at least not written).

fcb =Pointer to file control block.
fn =Pointer to file name. If NULL the FCB is assumed to contain a file name.
Return:Number of records in a file.

Include file: diskio.h