Question:
I am using Delphi 1.0 and am having a hard time trying to find commands/procedures/modules to lock a record from a Paradox database. What should I do to lock a single record from a database file for exclusive access?
Answer:
Paradox uses an “implied” locking scheme for locking records. Allyou need to do is start editing the record and it will be locked. You see,the BDE handles the locking for you. In this case, it’s better to check forthe existence of a lock once your user lands on a record using the BDE callDbiIsRecordLocked. Here’s how:
var IsRecordLocked : Boolean;DbiIsRecordLocked(Table1.Handle, IsRecordLocked);if IsRecordLocked then …do some stuff.
DbiIsRecordLocked checks for the existence of a record lock, then fills theBoolean input value with appropriate value.
Charlie has over a decade of experience in website administration and technology management. As the site admin, he oversees all technical aspects of running a high-traffic online platform, ensuring optimal performance, security, and user experience.























