I'm using a scheduler to launch a .bat file that then triggers a .vbs file that launches an MS Access database and runs a macro. I need to add a password to the MS Access database and i need to modify the .vbs file to send the database password so that it will automatically login. I can get it going in a module, but not the.vbs file. The following is my code. What code can I add and where can I add it so that the password is sent at the appropriate time?
********************
dim o
set o=createobject("Access.Application")
o.automationsecurity=1
o.opencurrentdatabase "C:\DB_S.mdb"
o.usercontrol=true
o.docmd.runmacro "All_Auto"
o.CloseCurrentDatabase
o.Quit
set o=nothing
********************
********************
dim o
set o=createobject("Access.Application")
o.automationsecurity=1
o.opencurrentdatabase "C:\DB_S.mdb"
o.usercontrol=true
o.docmd.runmacro "All_Auto"
o.CloseCurrentDatabase
o.Quit
set o=nothing
********************