Getting current record number

I am trying to get the current record number of a table using the code
from a Borland faq listed below.  I add the function to a form, and add
the uses given to the uses of the form, but when I try to compile, I
get the error 'Error in statement' on any line that uses 'Abort;'.  The
code compiles and runs fine without any of the FAQ code, but as soon as
I add the uses given in the FAQ, even without the accompanying function,
the error appears.  I am still new to this game, so please excuse me if
the answer is obvious.

----------------------------------- FAQ CODE -----------------------------
 uses DbiProcs, DbiTypes, DBConsts;

    function RecordNumber(Dataset: TDataset): Longint;
      CursorProps: CurProps;
      RecordProps: RECProps;
      { Return 0 if dataset is not Paradox or dBASE }
      Result := 0;

      with Dataset do
        { Is the dataset active? }
        if State = dsInactive then DBError(SDataSetClosed);

        { We need to make this call to grab the cursor's iSeqNums }
        Check(DbiGetCursorProps(Handle, CursorProps));

        { Synchronize the BDE cursor with the Dataset's cursor }

        { Fill RecordProps with the current record's properties }
        Check(DbiGetRecord(Handle, dbiNOLOCK, nil, @RecordProps));

        { What kind of dataset are we looking at? }
        case CursorProps.iSeqNums of
          0: Result := RecordProps.iPhyRecNum;  { dBASE   }
          1: Result := RecordProps.iSeqNum;     { Paradox }