DbaseIV: File already open

DbaseIV: File already open

Post by Mylene Marqu » Thu, 04 May 1995 04:00:00



Can some one suggest what might give me a File already open
error with the following code?

CLOSE ALL               && in the beginning, I find some SS
                        && that is in sec.dbf
USE SEC ORDER SS
SEEK my_ss

IF FOUND() = .T.
        ac_rec = RECNO()   && save the record number for later
        CLOSE ALL
        USE EMP ORDER SS
        SEEK my_ss
        IF FOUND() = .T.
           ss_rec = RECNO()   && get the record number for it in
           CLOSE ALL          && the emp.dbf
        ELSE
           CLOSE ALL
           RETURN
        ENDIF
ELSE
        CLOSE ALL
        RETURN
ENDIF

CLOSE ALL
USE SEC ORDER SS          && now I'm ready to delete the record
DELETE RECORD ac_rec
PACK          && this is where the error occurs or at the next pack
CLOSE ALL
USE EMP ORDER SS
DELETE RECORD ss_rec
PACK
CLOSE ALL
CLEAR ALL
RETURN

I can run it through once and it errors. I clear up
everything run it again once or twice and its ok.
Run it a third time and it errors.  (if this was C,
I'd say I had a null pointer or something).  This
error does not always occur on the same number of
run throughs.  I have not opened any other work
areas.

I have tried various versions of this, but they end
up with the same result.  I have isolated the error to
this code.  The de* shows me that things close
when I tell them to and that the databases open when
I tell them to.

This project is due next week and this is the final
error.  Please help.

Thanks in advance,

Mylene Marquez

 
 
 

DbaseIV: File already open

Post by Mylene Marqu » Thu, 04 May 1995 04:00:00


Please do not use the reply address on my last
post -- the address should be:


My apologies,

Mylene Marquez

 
 
 

1. Error opening file (already opened)

HI

I've got a strange problem using FMPro 4.0v2 for Windows. I've got a
database solution which contains 7 FMP databases. They interact with
each other.

The first DB is mainly a menu, allowing me to show one of the other
DB's. Opening this first DB also opens the other ones. The problem is
that when i push on button that should show another DB and perform a
script from that DB, FMP tries to re-open that DB (even though it's
already opened). Then it tells me the DB could not be opened because it
is in mono-user mode or the main user cannot be found. OK. Then it asks
me to find the DB. I open the right DB (in the same folder as the first
one), but it keeps me it's already open (in fact it is opened, but in my
FMP application).

Anybody got a clue on this ?

Thanks

JML

2. ODBC Problem conn. to Sybase, TDS bufferlength too large

3. Clear Excel data using VB Script - File Already Open

4. Personal Oracle and Oracle Client on same box - UPDATE

5. Reading/deleting in a shared textfile (error 55: File already open)

6. log space for alter fragment

7. File Already open Error

8. Upsize & Downsize Access SQL Server 2000

9. Determining if a File is Already Open

10. dbase IV 'file already open' error

11. Mail merge from Access try to open an already open DB

12. vb conflict to open DB already open with Access (error 3356)

13. Preventing a from from being opened - if already open