Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to determine if a FoxPro database is open

Status
Not open for further replies.

tjohnson

Programmer
May 10, 2002
4
US
Is there a way, outside of Visual FoxPro, to determine if a FoxPro database is currently open? We have a VB app that uses ADO to connect to a FoxPro database. Many of our customers share a database, and encounter problems when one user attempts to install an update while another user has the database opened.

I have tried the FoxPro DBUsed command, but it will always return False when the database is opened by an ODBC connection. I have also noticed that using "Exclusive=YES" in my ADO connection string does not really open the database in an exclusive mode (I can open the database through FoxPro at the same time).
 
Take a look at - a long time since I played with FoxPro (>4 years) for this sort of thing, but I think you'll find there's a flag that gets set somewhere between offsets 20 and 30.

mmilan.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top