pedie
Well-known Member
- Joined
- Apr 28, 2010
- Messages
- 3,875
Recieving error when i try to open Access and get data from it using excel as frontEnd.
Please suggest. It works perfect when the "Password:="123"
" is not added to that line...but i want to password through the proatcted access file...
"Runtime error '2147217843 (80040ed) Cannot start application. The workgroup information file is missing or open exclusively by another user."
Please help.
Thanks a lot!!!
PS: I also tried this way. but still same error.
Connection.Open ConnectionString:=Cnct, UserId:="", Password:="123", Options:=-1
Please suggest. It works perfect when the "Password:="123"
" is not added to that line...but i want to password through the proatcted access file...
"Runtime error '2147217843 (80040ed) Cannot start application. The workgroup information file is missing or open exclusively by another user."
Please help.
Thanks a lot!!!
PS: I also tried this way. but still same error.
Connection.Open ConnectionString:=Cnct, UserId:="", Password:="123", Options:=-1
Code:
Option Explicit
Sub OpenmyAccessFILE()
Dim DBFullName As String
Dim Cnct As String, Src As String
Dim Connection As ADODB.Connection
Dim Recordset As ADODB.Recordset
Dim Col As Integer
DBFullName = ThisWorkbook.Path & "\budget data.accdb"
[COLOR=blue]Set Connection = New ADODB.Connection[/COLOR]
[COLOR=blue] Cnct = "Provider=Microsoft.ACE.OLEDB.12.0;"[/COLOR]
[COLOR=blue] Cnct = Cnct & "Data Source=" & DBFullName & ";"[/COLOR]
[COLOR=blue] Connection.Open ConnectionString:=Cnct, Password:="123"[/COLOR]
Set Recordset = New ADODB.Recordset
Set Recordset = Nothing
Connection.Close
Set Connection = Nothing
End Sub
Last edited: