473,495 Members | 2,058 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Access2007 PW protected Run-time error'-2147467259(80004005)'

1 New Member
Run-time error'-2147467259(80004005)'
Could not use
'C:\TestDB\Netfront\Netfront.accdb';file already in use

I have to enter a password to open my DB. once the DB is open, and I click on a form button that has some VBA that issues a "cnn.Open" command I get the runtime error. see code sample. the variable SupportDBPath2 is define as follows.

Expand|Select|Wrap|Line Numbers
  1. Public Const SupportDBPath2 = "C:\TestDB\NetFront\"
  2.  
  3. Function ValidateShipmentEvents7()
  4.  
  5.     Dim cnn As New ADODB.Connection
  6.     Dim cmd As New ADODB.Command
  7.     Dim rst As New ADODB.Recordset
  8.  
  9.     cnn.Open "Provider=Microsoft.ace.oledb.12.0;Data Source=" & SupportDBPath2 & "NetFront.accdb;Persist Security Info=False"
  10.  
  11.     cmd.ActiveConnection = cnn
  12.  
  13.     rst.Open "SELECT * FROM [Distinct Query Date Final]", cnn, adOpenDynamic, adLockOptimistic, 1
I have numerous cnn.Open & rst.Open thru out my DB VBA. any help would be appreciated. thank you.
Oct 2 '10 #1
0 1124

Sign in to post your reply or Sign up for a free account.

Similar topics

19
8416
by: Rodger | last post by:
Hi all, I am getting the following error. ***************************** Microsoft JET Database Engine error '80004005' 'O:\DATA\DSR\DSR_DATA.MDB' is not a valid path. Make sure that the...
2
2524
by: nikou_70 | last post by:
I put my website on server ,I can see all pages but when I try to delete a record in (delete page)it shows (page cannot display),and when I write click on page the address of page is:...
0
7160
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7196
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6878
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5456
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4583
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3088
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3078
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1405
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
649
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.