ReportBro User Guide
|Text||A text element can consist of static text, parameters, a combination of both or an expression to be evaluated (see expression syntax for usage details. Predefined styles templates can be applied to text as well.|
|Horizontal line||A horizontal line is a simple design element that can be adjusted in regards of its width, height and color.|
|Image||ReportBro supports image types png and jpg with file extensions png, jpg and jpeg. An image file can be added statically by uploading, defining a text parameter with an URL as source (must start with http:// or https:// and end with its file extension) or defining an image parameter. When printing, images are scaled proportionally to keep aspect ratio and maintain printing quality. Thus, an image can be resized max. to its actual height and width (no stretching).|
A table is used to display a list of values, e.g. for invoices, statistics, shipping items. To print dynamic data a table needs a parameter list as data source. Have a look at table element and section element for further details. One click on the table selects the table itself, double click into the table selects a content element. Configuration and styling of contents is done the same way as for text elements. Have a look at the invoice demo and delivery slip demo to see how to use and configure tables.
Tables can be configured on different levels:
To perform grouping of rows inside a table you first need to create multiple content rows.
Select the table element and enter 2 into the field "Content rows"
(or a higher number in case you have more grouping rows).
Now you'll see multiple content entries below the table entry in the menu panel.
Select the new content entry and enter a "Group expression".
This row will then only be printed whenever the group expression value changes.
If you want to show a header for each group your content row with the "Group expression" must be
above the real content row (the one without any "Group expression"), otherwise it must be below to
show a footer for each group.
Hiding a table columnDisplay of table columns can be condition-based: Select a header column and define a print condition within the print settings to show the whole column only in case the condition applies. If you want other table columns to take up the space of hidden columns define the grow weight of each header column. If no grow weight is defined its width remains as predefined in the layout.
|Barcode||ReportBro currently supports Code128 as barcode being one of the most versatile barcodes and supporting all 128 ASCII characters. See ASCIItable.com for a list of supported characters. Have a look at the delivery slip demo to see usage of a barcode.|
|Frame||A frame is a container for other elements and stretches according to its contents. It can be used to group elements and keep them together (a frame doesn't split on page break) and to apply a border or background to the whole frame. All elements of a frame are positioned in relation to the frame whereas the frame itself is positioned in relation to the page. Therefore, moving the frame also moves its contents. Both invoice and delivery slip demos use frames.|
A section allows to print grouped lists of values. It needs a parameter list as data source (like a table). The difference to a table is, however, that a section can contain multiple elements to be grouped whereas a table displays data line by line. A section can be forced to be always printed on the same page.Sections can be configured on different levels:
Section element itself: Data source setting, position, enabling/disabling section header and footer
Section header, content and footer element: Height, shrink content to height. Set "Always on same page" to prevent element splitting on page break. Section header can also be repeated on every page in case the section spreads over more than one page.
|Page break||A manual page break|
You may set different behavior for styling text elements and printing based on evaluating an expression (see expression syntax for details on how to write expressions). Conditional styles are useful e.g. for highlighting a value if it is outside a certain treshold.
Print conditions may be helpful e.g. to address different payment terms on invoices based on tax rates or invoice amounts. An example on how to apply a style condition can be found in the delivery slip demo where the tare value gets a highlight color if it is greater than 0.
Parameters are used to pass data from an application to ReportBro in order to fill the report with dynamic data. ReportBro offers different parameter types that can also be used to evaluate expressions.
By activating the "Nullable" setting the parameter value can be set to the special value null instead of an actual value. A parameter that is not nullable and has no assigned value will automatically get a default value assigned (e.g. current date for date parameter, 0 for number parameter).
|Text||Takes any string.|
|Number||Numbers are interpreted for calculations as decimals, but can be formatted using patterns.|
|Boolean||True or false value.|
Dates can be formatted using patterns.
|Image||Using an image parameter instead of a URL or uploaded file.|
|List||Contains a list of parameters. A list can only be used together with a table or section element to represent the data from the list. However, a table or section may also contain other parameters than of its list data source. Please also have a look at table element and section element for further details.|
|Simple List||Contains a list of parameters of one specific type (text, number, boolean or string).|
|Collection||Contains a logical grouping for text, number, date, sum and average parameters. You may e.g. create a collection named "Client" that contains all address and contact details of your client.|
|Sum||Provides the calculated sum of a list parameter of type number. A parameter to use for calculation must be set as expression and only parameters of type number from a list can be used. For individual calculations use a parameter of type number and create your own expression.|
|Average||Calculates the average of a list of numbers. A parameter to use for calculating the average must be set as expression and only parameters of type number from a list can be used.|
|Arithmetic operation||+, -, /, *, %||
|Comparison operators||<, >, <=, >=, ==, !=||
|Logical operators||and, or, not||
|Conditional statement||value if cond else other_value||
|len(x)||Return number of elements in a list x or the length of a string x||
|str(x)||Convert x to a str (unicode in Python 2)||
|int(x)||Convert x to an int||
|float(x)||Convert x to a float
NOTE: there can be rounding issues when using float types due to the way how floats are stored internally (see also Floating Point Arithmetic) .
|decimal(x)||Convert x to a decimal.Decimal
NOTE: number parameters are saved as decimals, so you cannot use floats when performing arithmetic operations with number parameters. Always pass a string parameter to decimal function to avoid any possible rounding issues with floats. e.g. decimal('3.4') instead of decimal(3.4), the latter would result in 3.3999... instead of 3.4
|randint(x)||Return a random int below x||
|rand()||Return a random float between 0 and 1||
ctrl + C (Windows, Linux)
+ C (Mac)
|Copy the selected element to the clipboard|
ctrl + V (Windows, Linux)
+ V (Mac)
|Paste the content of the clipboard into the template|
ctrl + Z (Windows, Linux)
+ Z (Mac)
|Undo the previous command and also undo multiple commands. This can also be done via the button in the menu bar.|
ctrl + Y (Windows, Linux)
+ Y (Mac)
|Redo, reversing the undo command. You may also redo multiple commands. This can also be done via the button in the menu bar.|
|esc||Close a popup window shown for selecting parameters, patterns or to enter test data for lists. Content provided within a popup window is always saved.|
|Delete the selected element. This can also be done via the button next to the element in the menu panel.|
||Move the selected element pixel by pixel. You may also enter the exact position of the element in the detail panel.|
drag element + ctrl
|Move the selected element pixel by pixel (instead of 10 pixel steps when dragging an element with mouse or touchpad).|