Module 5 Databases Reports - Openoffice and Microsoft Access

Creating a Report in OpenOffice using the Wizard

End of OpenOffice reports

Microsoft Access

Create Reports


Present selected data in a particular sequence on screen and in reports.

To create a columnar report using AutoReport Wizard - Open a database and click on the Reports icon. Click on the New button. Select the table or query where the objects data comes from. In the example shown we have selected Customers from the Northwind database.· Select AutoReport: Columnar.
· Click on the OK button and the column formatted report will be generated and displayed on the screen.


To create a tabular report using AutoReport Wizard · Open a database and click on the Reports tab.· Click on the New button. · Select the table or query where the objects data comes from. In the example shown we have selected Customers from the Northwind database.
· Select AutoReport: Tabular.· Click on the OK button and the table formatted report will be generated and displayed on the screen.


To sort records within a report - This page of the Report Wizard allows you to sort your records by up to four fields, in either ascending or descending order.
In this case we have chosen to sort first by CompanyName and then by Phone, as illustrated. - Click on the Next button to continue to the next page.


To determine the layout of a report · The next page of the Report Wizard allows you to determine the layout of the report. You can select a Columnar, Tabular or Justified layout.· You can set the page orientation to Portrait or Landscape.· You can automatically adjust the field width so that all the fields fit on the page. · When you have selected the options you require, click on the Next button to continue to the next page of the Report Wizard.

To determine the style of a report · The next page of the Report Wizard allows you to select from a range of styles, Bold, Casual, Compact, Corporate, Formal or Soft Gray. When you have selected the required style, click on the Next button to continue to the next page of the Report Wizard.


To name a report · The next page of the Report Wizard is the final page, which allows you to give a name to the report. · Enter the report name in the top text box.· By default the Preview this report button is selected.· Click on the Finish button to generate and preview the report.
· The final report is displayed on the screen, as illustrated.


Modify a report.

To open a report in Design View · Open the Database Window.· Click on the Report icon.· Right click on the name of the report you wish to edit and select the Design View command from the pop-up menu.

To display the toolbox · Choose Toolbox from the View menuOR click on the Toolbox icon on the standard toolbar.

Report controls There are three types of control and they are described below.
Bound Control Bound controls are used to display data from fields in tables or queries. The values can be text, numbers, dates, logical (i.e. Yes/No), pictures or graphs. The most common type of bound control is a text box. It is normally more efficient to create your bound controls first.
Unbound Control A control that displays information such as text, lines, rectangles and pictures. An unbound control is not derived from a table.
Calculated Control The result of an expression.
The toolbox This is identical to the one available in Forms. All types of control can be created using the toolbox.

To create a bound text box · If the field list is not displayed, choose Field List from the View menu.· Select the field or fields in one of the following ways:
One field Click the field.

A block of adjacent fields Click the first field and with the SHIFT key depressed, click the last field of the block.
Several unconnected fields Hold down the Ctrl key while you click each field.
All fields on the field list Double click the Title Bar of the field list.
· Drag the field or fields onto the area of the form where you want them to appear. Multiple fields will retain their order in the field list.


To create a text box using the toolbox · Click the Text Box icon on the Toolbox. As you move the mouse pointer from the Toolbox to the form, it will change to a small box resembling the Text Box icon but with a cross outside the upper left-hand corner of the box.· Click the report where you want the text box to go.If you want your report to display a different label, click in the label box and type in your alternative text.

To create a label · Click the Label icon in the Toolbox.· Click in the area of the report where you want your label to go.· Type the text you want in your label.Alternatively, hold down the mouse button and drag the pointer to create a box of any size into which you can then type your label.

To create a bound control using the toolbox · Choose Field List from the View menu to display the field list.· Click the appropriate tool icon on the Toolbox.· Select a field from the field list and drag it to the report.

To create an unbound or calculated control using the toolbox · Choose Field List from the View menu to display the field list.· Click the appropriate tool icon on the Toolbox.· Click on the report.

To change the text of a label · Double click in the label.· Type in the alternative text.

To create a calculated text box · Move the mouse pointer over the text box. It should change to an insertion point (I?beam).· Type an expression.

Setting properties When you create a report, Access assumes properties for each of its controls and for the report and sections in the report. Bound controls inherit properties from the underlying tables or queries. You can make changes to properties in the Property Sheet.The Property Sheet appears with a display of properties. To view more properties, scroll through the list.
By clicking on the tabs, you can choose to see just Data Properties, Event Properties, Layout Properties or Other Properties.


The different property types are explained in the section on properties in forms. Here are some of the properties that are particularly relevant to reports:
Hide Duplicates Used to hide data in the control when it has the same value as the preceding record.
RunningSum Specifies a running total in text boxes. Can be set to Run over Group.
CanGrow, CanShrink Says whether a report section, text box or sub-report can shrink or grow to accommodate the amount of data. Cannot be used for page headers or footers.

To display the Property Sheet · Open a report in Design View and double click on a Control objectOR click a Control object with the right-hand mouse button and select Properties from the drop down menuOR choose Properties from the View menu.

top