Movicon Help on Line - Rel. 11.7.1301
Movicon offers an "Embedded Report" resource that can be used to create reports to display historical data or project variables. A Movicon Embedded report object is represented as a Screen object divided into five predefined sections called bands. Different objects and symbols, such as displays and charts, can also be added and become part of the Report's features.
Your license must be enabled with the "Data Logger" option in order to use the Movicon Embedded Reports or with the "Alarm Statistics" option when using Reports for Alarm Statistics. |
Embedded Report Resource
New "Textual Reports" or "Embedded Reports" can be added by using the following commands:
The "Add a new Report" command from contextual menu which appears when right-clicking on the "Embedded Report" group from the Project Explorer window.
The "New Report" command available from the "Commands" section located at the bottom left of Project Explorer Window.
The "Add a new Report layout in the project" available as an icon form the Movicon Toolbar.
When you add a new Report object, it will open in the Movicon workspace as a screen. The Report will be created with A4 paper sizes, which will be expressed in pixels and calculated by Movicon based on the screen resolution, with a white background, whose color can be changed afterwards, and divided into seven Bands. These bands also have their own default sizes which can be changed as appropriately needed. Each Band has a different role to play within the Report layout and will only be accepted for printing if it contains objects in the final report. The Bands are sectioned off with a separation line only in design mode to determine how much space can be used to add objects. They will not be shown in the final report. The seven Bands in question are:
Page Header (one per page): represents the area for the page header. This band will be repeated on all pages.
Report Title (one per report): represents the area for inserting the report title. This band will be printed once only on the first report page. When this band is printed as a single page (enabled "Keep in Separate Page" option), the "Page Header" will not be printed on the page dedicated to the report's title. The use of the Report Title band may result useful when needing to generate a multiple report which contains several reports that are printed all at once to show one report after the other when using the print command (see section on "Report-Recipes Commands"). In this case the "Report Title" will be repeated once on the first page of the first report listed, while the "Report Header" band will be printed for all the reports listed.
Report Header (one per report): represents the area for the Report Header and it is also a container for any graphs that need to be placed at the beginning of the Report. This band will be displayed on the first Report page only, after the "Report Title" band.
Details Header: represents the are for the "Details" band. If data in the Details area occupies more than one page, the "Details Header" band will be repeated on all the pages containing "Details" and it will be displayed before the "Details".
Details: represents the area in which objects are inserted (i.e. displays) to display variable values and historical log values extracted from the database by queries. This band, and the objects it contains, can be duplicated on the page and distributed to other pages when needed in order to display all recordset information obtained from the database by the query. If the Report has not been associated with a Database because if is being used for displaying RealTimeDB variable values, the Details band will not be show when creating the report. As a consequence, any objects inserted in this band will not be shown either.
Report Footer (one per report): represents the area in which Graph type objects (i.e. Trends) are arranged and shown on the last report page. This band will only show on the last Report page.
Page Footer (one per page): represents the area of the Page Footer. This band displays on all Report pages.
The Report Bands have a minimum size of 1 pixel and cannot be deleted or new ones cannot be added. The Band/s you wish not to display/print on your Report, simply leave them empty. |
Each Band can be configured through their "Height" and "Keep in Separate Page" properties, as described in the corresponding paragraphs.
Report Objects and Displayed Data
Different object types can be inserted in Reports to display data with. These objects are those contained in the "Toolbox Object" for Reports, which is made available when the Movicon Embedded report is opened in edit mode in the project's workspace. These objects are a subset of those that can be inserted on Screen and which are provided with a subset of properties.
Objects can also be copied and pasted from screens to Reports and viceversa. During this operation, Movicon will convert the object so that it is compatible with the new container in which it is inserted. For example, if you copy a "Button" that is not available for Reports from a Screen and paste if in a Report, it will be converted into a 'Radio button'. Some objects, such as the "List Box" and "Alarm Window" for example, cannot be inserted in a Report. The copying and pasting these objects in Reports will fail and a message will be generated in the output window as follows:
Cannot understand object type "ListBox" Nothing to Paste |
Also those objects that can be inserted in reports such as Screens, can be grouped into composed Symbols then inserted into the "Symbol Library".
The following type of data can be associated and displayed in Report objects:
Project's RealTimeDB variables (or child project)
Fields containing data extracted by queries from tables associated to the Report
Alarm statistical values (only when "Alarm Statistic" has been enabled)
Report or system information, displayable exclusively through predisposed objects such as the "Data Ora", "Utente", "Query", etc.
Values to be displayed in the Report objects can be inserted by editing the data entry fields manually or by simply selecting them from the "Tag Browser Window" window. In addition to the tab for selecting variables, there is also a "DB Field" tab from which you can select the database fields.
You can also manage some animation graphics for objects that can be inserted in the reports. This animations include Visibility, Transparency, background color, and others. This will allow you to animate specific objects in different ways based on the project's variable values. Object animations can only be edited while the report is being created. They cannot be edited when the report is displayed or printed. The following animations can be used:
Visibility (object may be made visible or invisible but it cannot blink)
Transparency (this functionality is not supported in Windows CE)
Scale
Rotation (this functionality is not supported in Windows CE)
Text - Display Value
Background Color
Dynamic Text and Text and Edge Color
Gradual Filling (available only for objects from the "Basic Shapes" category)
Dynamic Images (the object can display an image but the automatic scroll cannot be used with muliple images)
The animations above listed can also be used for objects in the "Details" section. In this case, as an animation variable, you can use the DataBase field instead of a variable and by doing so at each line displayed in the report, the object will be animated with the value of the current record. For example, let's suppose a display object has been inserted in the "Details" band to display a DataLogger field associated with the same Background Color animation as the one used for the DataLogger field. At this point, when the Report is generated, for example by extracting the last 10 records from the datalogger table, the ten display objects displayed in the Report will obtain a different set background colour based on the value shown.
Basic Expressions in objects
Basic expressions can also be inserted in object fields where variables are inserted. In this case, however, it is not possible to use expressions in database fields (DB fields, i.e. DF:VAR00001]) or special fields (SP fields, i.e. [SP:time]), where only variables from the RealTimeDB can be used.
Report and Alarm Statistics
By using the Movicon "Embedded Reports", you can create reports to display data recorded by the project's DataLoggers and Historical Log. Report's on project "Alarms" tables also allow reports to be created on alarm statistics, as described in the paragraph on "Alarm Statistic". You will find some ready-made reports on alarm statistics available in the Movicon installation folder which can be customized or you can create new ones.
In certain cases, it is also possible to generate reports on variable trace tables. In this case, the variable Trace must be set with the same DSN used by the DataLogger (or Historical Log). In this way the variable table will be created within the same DataLogger database (or Historical Log). When using Embedded Reports, the "DataLogger/Recipe" ( or Historical Log) item must be set as "Data Source Type", then the name of the DataLogger must be selected in the "Data Logger/Recipe" field (or a table in the "Event Log Type" field). At this point, it is essential that a customized "Query Report" be inserted to extract data from the variable trace table and not from the DataLogger table (or Historical Log). For example, if the variable being traced is called "VAR00001",and the table has the same name as the variable, the query will be:
Select * From VAR00001 Order By LocalCol DESC
Caution! When using the SQL Server CE, therefore in a device with Windows CE, it is not possible to create reports on variable trace tables, due to the fact that the database file created for tracing variables is different from the DataLogger database file and the Historical Log database file . |
Operations for editing Reports and multi-object selections
When editing Reports, you can execute specific operations by using the SHIFT key:
Selecting Report Properties: to display properties belonging to the Embedded Report resource in the Properties Window, simple click on the Embedded Report's name in the Project Explorer window or click on any Report band, in an area not containing objects, while keeping the SHIFT key pressed down.
Selecting Report Band Properties: to display properties belonging to the Embedded Report's Band, simply click on the band in an area not containing objects.
Multi-object Selecting: to select a number of objects contained in an Embedded report, as well as those belonging to different bands, simiply click on each object while keeping the CTRL key pressed down or by dragging the mouse while keeping the SHIFT key pressed down.
Modifying Band sizes: to change the band's height size:
change its "Height" property located in the Properties Window
select the interested band with the mouse, then click on the small square located in the center of the band's bottom separation line and drag it further down to enlarge or up to reduce it
select the next band to the one you wish to change, click on it with the mouse and drag it down to enlarge the one above. This operation method cannot be used for enlarging the "Page Footer" band which is the last one on the Report.
Functionalities which are not available in Reports
The Reports are used to display values of historically logged data for specific time ranges which can then be printed or saved as a document. However, once the Report has been created, it can no longer be edited. It is for this reason that functions and properties which are made available when editing the Screen resource are not available when editing the Embedded report resource and the objects which have been added.
The procedures which cannot be performed and the functions that cannot be used in the Embedded Report resource are:
It is not possible to edit Basic Script code within the Report resource or its object content.
It is not possbile to edit IL Logic within the Report resource or its object content.
It is not possible to use the Report resourse's local variables.
Objects inserted in Reports cannot be edited, therefore all the properties used for inserting data or for executing commands are not available for use.
Advantages and Disadvantages of using Movicon Embedded Reports
When reports have to be created within the project, it will be necessary to evaluate whether to use the Movicon Embedded Reports or the "Report Designer" or "Crystal Report" external libraries based on the type of report to be created. Below listed are the advantages and disadvantages of using the "Embedded Reports" compared to using the "Report Designer" or "Crystal Reports":
Advantages:
The Movicon Embedded Reports are compatible with Windows CE.
The Movicon Embedded Reports also support the "InMemoryDB" database format (along with any database limits).
Multilanguage reports can be created with the Movicon Embedded Reports by using the ready to use integrated change language management.
Vectorial graphics from the Movicon Symbol Libraries can be used in the Movicon Embedded Reports.
Variable values within the project can be displayed in the Movicon Embedded Reports without having to write script code.
Certain types of graphical animations, such as Visibility, Transparency, Background Color, etc., can be used within Embedded Reports which are evaluated during the Report generation phase.
The Movicon Embedded Reports integrate the advantages of using the Movicon editor while creating reports: Cross Reference, Refactoring, Renaming Management, Check for Missing Strings, XML Structure, etc.
The Movicon Embedded Reports for alarm statistics must not be modified when customizing the names of the Historical Data Log columns (Movicon will take this into account during the report generation phase).
The Movicon Embedded Reports show statistical information for each individual alarm for alarm statistics (Total Time ON, number of ON/ACK/RESET events).
Disadvantages:
The ToolBox used in the Movicon Embedded Reports contains a limited number of objects.
Sub-reports and automatic data groupings cannot be managed in the Movicon Embedded Reports.
Simple data calculations to be printed cannot be performed in the Movicon Embedded Reports (calculations must be first done using the Movicon logic whose results are then applied to the variable before generating the report).
Reports can only be saved or exported in "PDF" format when using the Movicon Embedded Reports.
Basic Script code ("wwb.com" or "wwb.net") cannot be used in the Movicon Embedded Reports to manage for managing reports in advanced mode.
Reports cannot be displayed on Web pages using the Movicon Embedded Reports.
Sub-reports cannot be used for alarm statistics with the Movicon Embedded Reports and, as a result, detailed alarm information cannot be accessed through report display windows.