AnsweredAssumed Answered

Globals and Robot Machines

Question asked by DLarsen on Jun 11, 2013
Latest reply on Jun 12, 2013 by DLarsen

I have series of reports that I'm trying to automate. It's basically a sales report by region.

 

What I'm trying to do is email a PDF for each region to the sales people that cover that region. There are a half dozen regions and maybe a half dozen people covering each region. Some sales people cover more than one region.

 

I have a sales order table and I have a sales person table. In the sales person table there is a field for region and a value list of check boxes that allow me to indicate which region or regions a given person covers.

 

I should probably mention that this is a Windows only deployment.

 

Normally I would run automation on the server but since I need the report in PDF format, and sever-side scripts don't allow the creation of PDFs, I'm forced to run this using regular FMP on an unattended robot machine using the native Windows Scheduled Task feature.

 

Basically I grab the full list of regions from value list and then walk through them one-by-one creating and saving the PDF. Then I go back and walk the list again this time setting a global field on the ORDERS table to the active region so I can pull the email addresses for the people assigned to that region.

 

It all works fine if I run it manually but as a scheduled task it won't pull the email addresses.

 

I've pretty much eliminated security as the problem as the account runs under [Full Access] in both files.

 

The really odd thing is that if I manually log into the robot machine using the Agent credentials it works fine. If I run it without logging in using the scheduled task, it fails. BTW, the scheduled task is configured to run using the Agent credentials.

 

This makes me think that global fields may not perform as expected unless the user is physically logged in. Has anybody else seen this?

Outcomes