Using the Report Builder of FastReport Desktop from the command line

2017-08-13

The FastReport Desktop software package includes the console Report Builder. Report Builder - a console program to automate operations with reports.

You can perform the following operations:

  • Batch processing of reports;
  • export to all available formats;
  • Connection data source;
  • send the results by e-mail;
  • Save results locally on ftp, and to cloud storage.

Report Builder is closely connected with the Configurator, which creates a special configuration files- instructions. These instructions allow you to set the report export, choose where to save the report and send reports by email. Builder receives these instructions and execute them on a schedule that is created in the Scheduler program. But nothing prevents to work directly with the builder through the command line. This can be useful if you want to export or send reports from own applications. Let's look at three ways of interaction with Report Builder:

  • Transfer a configuration file to Builder. To do this, run the Builder on Windows command line, and pass it the configuration file:

"Builder.exe path / to / config.xml"

Here, as you understand, the builder call with one parameter - the path to the configuration file;

  • Send configuration file to the Builder and override some of its parameters. You have the option to download the configuration file and replace the options you want, for example, a directory of saving report export:

"Builder.exe --Config-Path = path / to / config.xml --Save-Path =. / Dir"

That is to override the attribute you want to use the following scheme:

- Team {name} - {parameter name} = {value}

It turns out like this:

--Save-Path =. / Dir

In the case of override commands you need to specify the Config command to specify the path to the configuration file.

  • Send parameters-commands to the builder . With this approach, we do not load the configuration file, and in fact form the instructions for the Builder on the command line. Pass parameters, as well as the we define them in the Configurator. Let's look at an example:

--Report-Path="report.frx" --Export-As=image --Export-ImageFormat=Jpeg --Export-JpegQuality=80 --Save-To=folder --Save-Path="path/to/folder"

Since we do not load a configuration file --Config command is not needed. Note that we used the command --Export three times. For each export property you want to override (as opposed to the default values), you need to write command name.

Thus it is possible to define any parameter available in the Configurator. A full list of commands and properties (attributes) can be found in the documentation for FastReport Desktop.

So, we looked at different variants of working with console Report Builder. Now you can use it in conjunction with own programs, need only transmit a set of parameters.

November 26, 2024

Installing FastReport on .NET 8.0 and Creating a Simple Report

The purpose of this article is to explain step by step how to install FastReport on .NET 8.0 and how to create a simple report. Taking the reporting process from the beginning, it will show how to connect, design and view reports.
November 20, 2024

Localization and Language Switching in FastReport VCL

FastReport VCL supports 40 languages for interface localization and allows you to change the language on the fly through menus or code, without recompilation.
November 01, 2024

New Features of the FastReport VCL Editor

We are considering new features of the report editor: extension lines, highlighting of intersecting objects, updated report and data trees.
Fast Reports
  • 800-985-8986 (English, US)
  • +4930568373928 (German)
  • +55 19 98147-8148 (Portuguese)
  • info@fast-report.com
  • 66 Canal Center Plaza, Ste 505, Alexandria, VA 22314

© 1998-2024 Fast Reports Inc.