ms access - PowerShell run great but does not run as a scheduled task -


i have powershell script - opens ms access database, run vba script, , later close itself. runs manually.
scheduled user in 'administrator' of computer , e local drive.

however, when schedule windows task, hangs. codes below. tell me went wrong?

$access = new-object -com access.application $access.opencurrentdatabase("e:\audit\audit.accdb") $access.run("fun_run") $access.closecurrentdatabase() $access.quit()  [system.runtime.interopservices.marshal]::releasecomobject($access) remove-variable access 


Comments

Popular posts from this blog

ios - MKAnnotationView layer is not of expected type: MKLayer -

ZeroMQ on Windows, with Qt Creator -

unity3d - Unity SceneManager.LoadScene quits application -