|
-
Apr 12th, 2010, 01:37 PM
#1
Thread Starter
Fanatic Member
DAO Error Message
I'm using DAO in a multi-terminal situation. Sorry. Can't change it now without a total re-write and that's just not possible.
So here's my code (I added line numbers to help pin down the error):
The database is open in Read-Only mode:
Set DbLookUp = DB.OpenRecordset("Names", dbOpenTable, dbReadOnly)
On error goto ETrap
Temp$="SMITH"
590 DbLookUp.Index = "Last"
600 DbLookUp.Seek "=", Temp$
ETrap:
MsgBox "Error occured in " + Routine$ + "ERL: "+Str(Erl) + " Err: " + Str(Err) + " " + Error$
This generates the following error message:
Error Number: ERL: 600 Err: 3046 Could not save; currently locked by another user.
Note that I'm getting error 3046 - could not save. what the heck!?!? I'm not trying to save - I'm doing a seek. It's a read-only database anyway.
When someone wants to write into the database another routine is called that opens the database in read-write mode and updates the record. I open it this way:
Set DbWrite = DB.OpenRecordset("Names", dbOpenTable)
DbWrite.LockEdits = False
Any suggestions (other than upgrade to .NET or switch to RDO or whatever).
Thanks in advance!
--DB
Last edited by Darkbob; Apr 12th, 2010 at 01:40 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|