BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with ADO access permissions.

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop)
View previous topic :: View next topic  
Author Message
Mike H
Guest





PostPosted: Fri Dec 08, 2006 6:35 am    Post subject: Problem with ADO access permissions. Reply with quote



As a part of its startup my program retrieves data from an Access database
using normal ADO commands. I have used cmReadWrite as the connection mode
for these operations.

At a later point when attempting to compact the database in code I close the
connection and then attempt the compaction. I receive an error message at
this point telling me the the "database has been opened in exclusive mode by
Admin on XX. Please try again Later."

I am obviously using the wrong connection mode as I wish to open the
database in non-exclusive mode so it can be accessed from several locations.
I have tried using cmShareDenyNone without success and have not been able to
determine what connection mode I should be using.

Thanks for any and all help given with this problem.

Kindest Regards,

Mike Henry
Back to top
Brian Bushay TeamB
Guest





PostPosted: Fri Dec 08, 2006 9:11 am    Post subject: Re: Problem with ADO access permissions. Reply with quote



Quote:
As a part of its startup my program retrieves data from an Access database
using normal ADO commands. I have used cmReadWrite as the connection mode
for these operations.

At a later point when attempting to compact the database in code I close the
connection and then attempt the compaction. I receive an error message at
this point telling me the the "database has been opened in exclusive mode by
Admin on XX. Please try again Later."

I am obviously using the wrong connection mode as I wish to open the
database in non-exclusive mode so it can be accessed from several locations.
I have tried using cmShareDenyNone without success and have not been able to
determine what connection mode I should be using.

Thanks for any and all help given with this problem.
cmShareDenyNone is what you want to use for your application but a compact

database needs to have exclusive access to your database so you will have to
close all other connections before you run your compact database.
--
Brian Bushay (TeamB)
Bbushay (AT) NMPLS (DOT) com
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.