To run scheduled report distribution you will need to use Velixo.Reports.CommandLine.exe with the command line arguments provided in Windows Task Scheduler.

Setting up a task in Windows Task Scheduler

First, from the Start menu, select Administrative Tools > Task Scheduler. The main window of Task scheduler will be opened.

mceclip3.png

In the Actions panel, click Create Task.

mceclip4.png

In the Create Task dialog open the General tab, and enter the values for Name and Description:

mceclip6.png

On the Triggers tab click New and set up the appropriate schedule for your task.

mceclip7.png

Then click New on the Actions tab and fill in the required fields in New Action dialog:

Program/script:

"C:\Path\To\AppData\Roaming\Velixo\Velixo Reports Pro for Excel and Acumatica\Velixo.Reports.CommandLine.exe

Add arguments (optional):

--file "C:\Path\To\Workbook-File.xls" --distribution-list "Distribution List Name"

mceclip8.png

Click OK and open the General tab of the Create Task dialog. Ensure option "Run only when user is logged on" is selected.

mceclip0.png

For proper execution Velixo strongly recommends using this option. In case you absolutely need to run the distribution regardless of whether the user is logged in or not, advanced configuration is required. Officially it is not supported by Microsoft. See the "Advanced configuration for non-logged in users" section below for details.

Running the task

If you wish to run the scheduled task right away for testing purposes, right click on it in the list of tasks and select Run from the drop-down menu:

mceclip9.png

Note: In this example error handling is reporting errors to the command line. No logging is performing. Excel user interface is hidden during the distribution process.

It is also always expected for a command prompt to appear during the execution of the scheduled task. The command prompt closes immediately once the task is finished.

To set up the desirable scenario of a distribution process, you can use the corresponding options.

Options

Option

Required/Optional

Description

--file

Required

Path to Excel workbook to open

--distribution-list

Required

The name of distribution list to process

--log-file

Optional

Path to a log output file

--xll

Optional

Custom path to Velixo Reports XLL file. Normally you shouldn’t specify this parameter, by default it uses Velixo’s installation path

--silent

Optional

true (default) - Runs the process silently, returning error messages to the command line

false - shows error messages in dialog boxes

--visible

Optional

true/false indicating whether or not the Excel user-interface should be visible during the process. Default is false

Advanced configuration for non-logged in users

In the Console Root select Component Services -> Computers -> My Computer -> DCOM Config. Navigate to the Microsoft Excel Application at the right. Right click Microsoft Excel Application and select the Properties item in the drop-down menu. In the Microsoft Excel Application dialog, click the Identity tab. Select The interactive user option and click Apply to complete.

mceclip2.png
Did this answer your question?