Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hey everyone, I have a Access Database a user has to log in to when viewing the database based on security settings. I have the below code whish is accessing the database to dump info into from a Excel Form, but now it is giving an error message b/c of the security. I need to put the security in force b/c I had someone try to corrupt the database. How can I make the below code provide their login info so it will open the database and dump the data in? Public gcnAccess As ADODB.Connection Sub OpenAccessConnection() Dim sConnect As String Dim sPath As String sPath = ThisWorkbook.Path If Right$(sPath, 1) < "\" Then sPath = sPath & "\" sConnect = "Provider=Microsoft.Jet.OLEDB.4.0;" & _ "Data Source=" & sPath & "CARS.mdb;" Set gcnAccess = New ADODB.Connection gcnAccess.ConnectionString = sConnect gcnAccess.Open End Sub -- dok112 ------------------------------------------------------------------------ dok112's Profile: http://www.excelforum.com/member.php...o&userid=10581 View this thread: http://www.excelforum.com/showthread...hreadid=513398 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Closing Applications | Excel Programming | |||
Using VBA to select applications... | Excel Programming | |||
"Ignore other applications" | Excel Discussion (Misc queries) | |||
Other applications | Excel Programming | |||
macros for other applications | Excel Programming |