I keep getting this error: "The Microsoft Access database engine cannot open or write to the file ''. It is already opened exclusively by another user, or you need permission to view and write its data."
Obviously I have checked if the file is open, rebooted, etc. It is not open and it has full permissions!
Here is my code: (Highlighted is where the error is occurring)
Code:Dim PathToUse As String = "C:\WORK\A_TEST\" Dim MyConnection As System.Data.OleDb.OleDbConnection Dim MyCommand As System.Data.OleDb.OleDbDataAdapter MyConnection = New System.Data.OleDb.OleDbConnection _ ("provider=Microsoft.ACE.OleDB.12.0;Data Source='" & PathToUse & "';Extended Properties=Text;") MyCommand = New System.Data.OleDb.OleDbDataAdapter _ ("select * from [CommaDelimitedFile]", MyConnection) MyCommand.TableMappings.Add("Table", "TestTable") MyCommand.Fill(AddressListDatatable)




Reply With Quote
