invincibleian
Programmer
My procedure below worked fine until I put a password on the database. Now a "Enter Password" prompt appears. Is there anyway to write the password into my code?
Public Sub fPrintSummary(strReportName)
Dim applAccess As Access.Application
Set applAccess = New Access.Application
applAccess.UserControl = False
applAccess.Visible = False
applAccess.OpenCurrentDatabase "\\Dph_vitals_nt\VtlDev\Administrative File System\FileSystem.mdb", True
applAccess.DoCmd.OpenReport (strReportName)
applAccess.CloseCurrentDatabase
applAccess.Quit acQuitSaveNone
Set applAccess = Nothing
End Sub
Public Sub fPrintSummary(strReportName)
Dim applAccess As Access.Application
Set applAccess = New Access.Application
applAccess.UserControl = False
applAccess.Visible = False
applAccess.OpenCurrentDatabase "\\Dph_vitals_nt\VtlDev\Administrative File System\FileSystem.mdb", True
applAccess.DoCmd.OpenReport (strReportName)
applAccess.CloseCurrentDatabase
applAccess.Quit acQuitSaveNone
Set applAccess = Nothing
End Sub