Powershell script errors using Task Scheduler

Good morning everyone,

I am hoping that someone might be able to help figure out why my task scheduler is not running my full powershell script. Basically the script will run half way, and when it is time to open an Access database the task scheduler will throw error (screen shot below).

I have also included a snap shot of my task scheduler settings and the powershell script. I appreciate any suggestions!

I don’t believe Microsoft supports using office com objects in task scheduler, it needs an interactive session.

You may have some success getting it to work, but I’ve seen plenty of people over the years banging their heads against the wall just attempting similar tasks.

Thank you for the reply. I am curious to see if there are alternatives to windows task scheduler. I would like to be able to automate my powershell script to run once daily. The script runs perfectly, the only challenge now is to have execute on it’s own :stuck_out_tongue:

Daniel,
Welcome to the forum. :wave:t3:

Please don’t post images of code or console output or error messages. Instead post the plain text and format it as code … .

When you post code, sample data, console output or error messages please format it as code using the preformatted text button ( </> ). Simply place your cursor on an empty line, click the button and paste your code.

Thanks in advance

How to format code in PowerShell.org 1 <---- Click :point_up_2:t4: :wink:

You don’t need a an alternative to the task scheduler you need an alternative to the Office com object you’re using in your script.

For Excel for example that would be the great module from Doug Finke

There might be modules out there able to work with Access databases.