Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Checking for Exclusive Use of a Database
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00137397
Message ID:
00137704
Views:
22
>Hi There,
>
>I'm trying to test a database container to see if it is being used by any users before doing an exclusive open on it. I need to do this test without generating a VFP error event.
>
>I do not want to use the ON ERROR command to trap the error message that is generated.
>
>Does anyone have a good way of doing this?
>
>Thanks in advance,
>
>Ben Holton

Hello Ben,

Another way is to open the DBC using low level function FOPEN(). if FOPEN() returns -1 then check the failure using FERROR() and error is 'File access denied' do whatever you want to do.

Bye
Jayesh
- Jayesh
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform