![]() |
Report Designer |
Click here to go to Help Index |
Designing and Creating Reports | ||
QReport, the Report Designer QReport is a fully-functional Report Designer that runs as a standalone desktop application. Report Designer is a modified version of DataDynamic's highly-rated end-user Report Designer. The designer is completely scriptable (using the C# language) with access to all events, including:
With the designer, you can design virtually any type of report, test it and upload it to the central server site, so that it is available to you or any authorized user at any time. The designer will be familiar to anyone who has worked with contemporary report designers. The installed version includes:
Loading an existing standard report for customizing: example: order form
Interfaces:
Designer: The designer is sectioned into:
Objects:
Drag/drop objects onto the applicable section of the report. Assign data fields where applicable. Right-click to format border, send to front/back and other options.
Selecting an ODBC Data Source - the basic database When you installed the Desktop (which included QReport Report Designer), the installation program will have automatically installed a Microsoft Access database that contains the base tables and fields used in the central database and an ODBC data source. Although your custom fields will not be in this database there is often sufficient to work with for most report design purposes. It's named Q_LocalAccess and you can access it from the drop down list in the Construct Query Form (see below-click here) for most of your data design purposes. If you want to access the actual central database, you will need to work with your administrator to set up an ODBC Data Source pointing to that database.
Setting up an ODBC Data Source: The Report Designer accesses any database through the ODBC Data Source Administrator. Have your administrator set up an ODBC Data source to your database, or, better yet, to an extracted, field-only Microsoft Access version of your database. We strongly recommend the latter. The administrator would create a Microsoft Access database from the company's central database, with that Access database containing no data, just the "schema". The administrator would then copy the Microsoft Access database to your computer (or the computer where you are running the Report Designer) and would set up an ODBC Data Source on that computer pointing to that Access database. A "field-only" copy with no data is much safer from a security viewpoint. Another alternative is to use a standard Microsoft Access database by contacting us. That database won't have any of your custom fields, but you can either add them directly to the Access database or create your reports without those fields. If you need more help on setting up and ODBC Data Source, write us describing your needs and we will point you to some help.
Data: Click the yellow data container to specify the data source and create the SQL expression. See Construct query form below. After clicking [OK] from the Construct query form, the fields contained in the SQL expression will display in the right-hand field list area: Drag/drop fields onto the applicable section of the report. Use the up/down/left/right arrow keys to absolutely position the objects. Use the mouse to increase/decrease height/width, or set the applicable property for the object. Set CanGrow to true to allow automatic expansion of the height of the object where the content dictates. The report will expand by that amount. Consider using a before print event to evaluate the size of text boxes, and limiting their display height based on number of characters in the text box. Set CanShrink as needed. Create summary fields as textboxes, set the distinct field to be summarized on, set the summary criteria. Right-click in the design workspace area to insert Report Header/Footers, Page Header/Footers (if not already on the report), Group Header/Footers.
The construct query form is used to design moderately-complex SQL expressions, including linked fields and joins. For more complex designs, use any other query builder (including Microsoft Access) to create the expression, then paste that expression into the SQL display box.
Table
list: click on a table name, drag/drop onto an empty part of the
work area or drag/drop onto an existing table header box
Joins: click and hold on a source field and drag/drop on a destination field. The link will display in the destination field's link area.
Scripting: The report designer accommodates full scripting, with access to all events. Click the script tab at the bottom of the designer to invoke the script page:
Some script examples - NOTE: always save your layout after making script changes in order for the changes to take effect.
public void GroupHeader1_BeforePrint() public void ActiveReport_ReportStart() public void GFOrderID_BeforePrint()
Save layout - upload to the central server: After designing and saving a report layout, use the Report File Manager module to upload it to the CustomReports folder on the main server. You can then use the Reports module to fetch and run the report (ensure you click the Custom reports option button beside the "Select a report" option. Below,
the
After
uploading the layout, use the Report module to access and
run the report. Note that the
Run the report Send a file to your browser
Open the report
|
||