USE DBF if exclusive open in other program

Xbase++ 2.0 Build 554 or later
Post Reply
Message
Author
Victorio
Posts: 621
Joined: Sun Jan 18, 2015 11:43 am
Location: Slovakia

USE DBF if exclusive open in other program

#1 Post by Victorio »

Hi,

I have some unintelligible problem.

I want open database, which is shared with other Visual Foxpro application (not mine). In this Fox app is database opened Excusive (I do not know, why autor did this,but it is not possible force him to change it) , it is fact.

because I cannot open this datbase SHARED and also READONLY .
My alternate solution is copy this database to my temporary directory and here open.

What is important, two VFP programs can open this same database , only my Xbase++ app can not, or better to say, If I open DBF SHARED, or READONLY,
VFP APP say Access Denied.

How can I open this database without problems with Access Denied in VFP APP ?

I have tested also connection via ODBC driver , same result.

User avatar
rdonnay
Site Admin
Posts: 4728
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: USE DBF if exclusive open in other program

#2 Post by rdonnay »

How do you know that the VFP program has it open exclusive?

It may be a compatibility issue.
The eXpress train is coming - and it has more cars.

Victorio
Posts: 621
Joined: Sun Jan 18, 2015 11:43 am
Location: Slovakia

Re: USE DBF if exclusive open in other program

#3 Post by Victorio »

open exclusive : author this VFP application tell me ....

But is possible he open this database for very short time , then close, maybe ... I am not sure, if in this time run my app VFP cannot open exclusive,
I tryed open two VFP application at once several times, but any problem :think: , only when my app is opened.

I suppose, is not way to get around exclusive open, and I must realise it with compromise.

Now I have this solution :
copy database as file to another temporary
DC_FileCopy(subor,cestatemp,"Vytváram pracovnú kópiu súboru STxxxxxx.DBF...")
DC_FileCopy(suborcdx,cestatemp,"Vytváram pracovnú kópiu súboru STxxxxxx.CDX...")

then open it.

But I must input some control, if DBF and CDX are copied correctly, to prevent crash reading it.

Problem is, that to database writing permanently , online, and changes I can see only after another copy process.

User avatar
Auge_Ohr
Posts: 1405
Joined: Wed Feb 24, 2010 3:44 pm

Re: USE DBF if exclusive open in other program

#4 Post by Auge_Ohr »

Victorio wrote:open exclusive : author this VFP application tell me ....
...
How can I open this database without problems with Access Denied in VFP APP ?
easy ... speak with the author and tell him "why" you "wish" to put some Data into those DBF.

remember it might have a reason why other author is using EXCLUSIVE Mode !
greetings by OHR
Jimmy

Victorio
Posts: 621
Joined: Sun Jan 18, 2015 11:43 am
Location: Slovakia

Re: USE DBF if exclusive open in other program

#5 Post by Victorio »

Jimmy, I have spoken with autor, he used exclusive for easy access database for changes structure, or some reorganisation data in it.
But he has health problems , then he do not work on this. It's complicated, because only he has source code :snooty:

Post Reply