I have updated a phone directory and put the data into an access database.
I was using the below Process.Start command to open the text file.
I thought I could use a similar statement to open an access database for viewing, but it didn't work.
So I googled it found a piece of sample code, tweaked it to the correct path, but it didn't work either.
Could anyone point me in the right direction possibly?
Thanks!
Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
'Process.Start("nProcess.Start("notepad.exe", "P:\lsp2\misc\Phone.txt")
'first try, just use the same "process.start" type statement.... didn't work!!!!!!
'Process.Start("nProcess.Start("msaccess.exe", "P:\lsp2\misc\Phone_Directory_2013.accdb")
'*********************************
'Second try, using sample cod off the net..... didn't work!!!!
'Dim oAccess As Application
' Start a new instance of Access for Automation:
'oAccess = New Access.ApplicationClass()
' Open a database in exclusive mode:
'oAccess.OpenCurrentDatabase(filepath:="P:\lsp2\misc\Phone_Directory_2013.accdb", Exclusive:=True)
'*********************************
End Sub