How to make regular reports mailing using FR Desktop

Nowadays, users quite often face a task to form periodic reports, send them by e-mail or save in a specific location. Implementing  such tasks is not difficult with our report generator. However, it is necessary to create an application that will work with the report generator. It requires some programming skills and experience in programming field. But what if you do not have such experience, or you do not want to buy expensive licensed development environment (e.g. MS Visual Studio)?

FastReport Desktop allows you to solve these issues. This is an independent program complex, that does not require creation of custom applications. Consequently, it does not require programming skills either. Desktop allows to: create reports, configure them on a schedule, export a report to different formats, send an email report, save reports on a local drive or on remote resources.

Let us take a close look at this software package. It is presented by five programs:

- Designer - a program to create a report template;

- Viewer - a program for viewing reports;

- Builder - a console program - a Report Builder;

- Configurator - a program for creating configuration files, containing instructions of processing a report;

- The Scheduler - a program - task scheduler to build reports by schedule.

In the diagram there is a technological process of working with FR Desktop:



So, our aim is to organize a daily report generating and sending it by e-mail.

1. First, create a report using the designer (Designer). To do this, run an appropriate program. I created a simple report of a Master-Slave type, which displays a list of categories with products. The template looks like this:

 Save the report on the local disk.

2. Now, create a configuration file. This file describes the actions, that a builder has to do with a report. Run the program Configurator:


Create a new configuration file. To do this, we go through the options on the form and set the required ones. First of all, we select the report file:


We skip the next option "Report Parameters". As you understand from the title, it allows you to set values for report parameters. Here is a form for editing report parameters:


Next, we can specify the data source for the report. As our report uses an internal data source, we skip this option. This is how the form of connection editing looks like:


The next option is "Export". We need a report in PDF format. It is selected by default in the list of available export formats:


The "Settings" button allows you to set export options:


For example, the "Text in curves" option allows you to draw text in a report, using curves, which makes the process of copying text impossible.

You might be asked to choose a place, where to save your report. This is not our task, so you can skip this step. But I will show you a list of possible places to save:


The next step is to set the email settings:


The report file will be attached to an e-mal.

It is necessary to fill in the settings of outgoing e-mail server:


On the E-mail tab fill in the message parameters:


Now, in the main form, click the "Save" button.


It is important to save the configuration on the local disk. Interestingly, that the "Run" button allows you to start the configuration immediately. Close the program and proceed to create a task in the Scheduler.

3. Start the Scheduler:


 The interface is simple and straightforward. Add a new task using the "Task" menu:


The form of task creation is also intuitive:


Sets the name of the task, the configuration file and the trigger. By default, a trigger "Every day" has been selected. For this trigger you need to set the date, time of operation and the frequency of repetition.

A set of triggers covers all possible needs:


Click the "Create" button. The main form has a new task:


So, we see that the task is enabled and the last run is still empty. Now we have to wait for a while.

The task has been executed at a specified time. The mark of this has appeared in the "last start time". The report will be formed every day and will be sent at this time.

Now, check the mailbox:


Here we see an email with our report in PDF format.

To sum up, we have overviewed a procedure of making regular reports mailing, using FastReport Desktop, which seeks to ease the process and reduce manual work.