_BtDelete() Function
<< Click to Display Table of Contents >>
_BtDelete() Function
|
|
Purpose
Deletes the current record in an open Btrieve File
Prototype
FUNCTION _BtDelete ( hFile AS PTR ) AS LOGIC
Argument(s)
<hFile> | File handle that was returned by _BtOpen |
Return
LOGIC | Was the delete operation succesful. |
Description
With this function you can delete records from a file
The following prerequisites apply when performing a Delete operation:
•The file must be open.
•You must have a physical or logical current record in the file. This requirement is satisfied IF the previous operation was a valid Get (except Extended Gets or Get Key), STEP (except Extended Steps), Insert, or Update.
•To delete (or update) a record while inside a transaction, the record must have been retrieved while inside that transaction and not before.
Positioning
The Delete operation destroys the complete physical location information and the logical current record position but leaves the positions of the logical next record and logical previous record unchanged.
When an error occurs deleting the record , the return value is FALSE and the Bt_Error() function returns one of the following values:
08 | Invalid Positioning |
14 | Pre-image Open Error |
15 | Pre-image I/O Error |
80 | Conflict |
83 | Read Outside Transaction |
See Also