Windows 2008 R2 Not Printing From Scheduled Task

microsoft accessprintingscheduled-tasksessionwindows-server-2008

Problem

Since the end of support is coming on July 14th for Windows servers 2003 we are moving all of our scheduled tasks to a Windows 2008 R2 server.

We use a Microsoft(MS) Access 2003(mdb) database to handle various backend processes that compliment user and customer interactions with our system.

One of the backend processes inside of MS Access, the cause of this question, is refusing to print when a user is not logged in.

The backend process populates a temp table, that is later used to populate the report that is supposed to print out. This report has an embedded query, linked images and a saved default printer.

The user that is executing the scheduled tasks is a domain user.

What We Speculate It Might Be

Session 0 Isolation – Access has a very small printing window that comes up that shows that you are on page X of N. This window cannot be interacted with. I feel that this may be the culprit, but everything we have tried has not worked to stop it.

What We Have Tried

  1. Created Desktop folder under system profile
  2. Made sure user is local admin with elevated privileges
  3. Manually running it while logged in (This works)
  4. Creating a miniature version of the application that does a small sample of the print job.
  5. Setting the scheduled task to run if the user is logged in or not. Regardless, the other processes in the MS Access database still run, and we get the empty report for the process that is not printing.

Current Workaround

We are keeping the domain user logged in.

Best Answer

This problem can easily occur if you print to a session printer.

HKEY_Current_User\Printers\Connections (session printers)

vs

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers (local printers)

Any printer installed over a network share will fall in that category. Please try again with a printer installed with a local tcp/ip queue, that printer will be available system wide.