Hi,
I have an Access 2007 db .
I am the only user and developer.
I click on access and it takes me to a Switchboard I created.
I exit out of the switchboard.
I want to edit a procedure in a module.
So I click on the left side of the screen. Select the subroutine I want.
I make the changes to the subroutine. Go to run it .
I get the message . The database has been placed in a state by user "Admin" ....... that prevents it from being opened or locked.
If I comment out the code cnn1.Open CurrentProject.Connection. The subroutine works. Why is this happening? Why can't I just make the changes I want without commenting out the connection statemement?
Public Sub sumix()
'Set up the connection object , name it cnn1 .
Dim cnn1 As ADODB.Connection
Set cnn1 = New ADODB.Connection
cnn1.Open CurrentProject.Connection
'Declare record set
Dim rst As ADODB.Recordset
Set rst = New ADODB.Recordset
I have an Access 2007 db .
I am the only user and developer.
I click on access and it takes me to a Switchboard I created.
I exit out of the switchboard.
I want to edit a procedure in a module.
So I click on the left side of the screen. Select the subroutine I want.
I make the changes to the subroutine. Go to run it .
I get the message . The database has been placed in a state by user "Admin" ....... that prevents it from being opened or locked.
If I comment out the code cnn1.Open CurrentProject.Connection. The subroutine works. Why is this happening? Why can't I just make the changes I want without commenting out the connection statemement?
Public Sub sumix()
'Set up the connection object , name it cnn1 .
Dim cnn1 As ADODB.Connection
Set cnn1 = New ADODB.Connection
cnn1.Open CurrentProject.Connection
'Declare record set
Dim rst As ADODB.Recordset
Set rst = New ADODB.Recordset