Você está na página 1de 4

Session 22: Attachment 1

ATTACHMENT 28-1: WRITING REPORT USING MBWIN REPORT BUILDER


The MicroBanker Report Designer
The MicroBanker Report Designer is a tool for writing reports that has been
included in the MicroBanker SRTE system. Its goal is to provide a complete
reporting solution that allows you to create your own report. Its interface is fully
Microsoft Office compliant and can be easily learned.
There are four areas that you have get familiar with when designing a report,
these are the Data Access, Data Process, Report Layout, and Report Output.
Each of these is visually represented as the four tab pages in the Report
Designer, which are Data, Calc, Design and Preview respectively. These tab
pages contain visual components, which give you the ease of creating and
designing your report. The results of each area becomes input to the next area,
data feeds into calculation, calculation feeds into the components within the
report layout, and report layout is then rendered into the preview of the report.
Data Tab
This is the area where you can create Dataviews, which are then used to supply
the data for the report. Dataviews allow you to select the tables, fields, search
criteria, and sort order that you are going to need as the output.
Calc Tab
This workspace contains the view of the report in a tree-view format. This treeview includes the bands in the report and all the components or objects within
each band. When a band or a report component is selected, all the events for
that object are shown in a list. You can then select an event and write a piece of
code at the code editor located at the bottom.
Design Tab
The Design workspace contains the actual layout of the report. The Microsoft
office interface-style helps make the designing easy to learn and use. This area
is the place holder of the all the visual components or objects of the report you
are writing.
Preview Tab
The preview workspace contains the rendered report and the final result of your
hard work. The report can be printed to the printer or to various formats, which
the system supports.
Learning to Write the Report
This simple introduction will help you get started with the basic components of
report writing. As a starter, it will take you through a series of exercises to get
you familiar with the Query Wizard and components of the Design Workspace.

22-1

Session 22: Attachment 1

Getting Started
The purpose of this section is to show you what it takes to build a report. It will
help you get oriented with the basic parts of report designing as mentioned
above.
I.

Query Wizard
Click on the Data Tab
Select File | New in order to access the New Items dialog.
Double-click on the Query Wizard icon.
The Query Wizard will come-up with a list of available tables.
Choose the CIF table by double clicking on it. It should now appear on
the list of Selected Tables.
6. Click Next until you reach the option to Define Search Criteria.
7. Click on this option to display the list box for Criteria.
8.
Right click on the list box and select Insert Criteria, this will open the
Search Criteria dialog.
9.
On Field option, locate and select CIF.Type, change the Operator to
<>, and set the value to 499. Click OK.
10. Click the Next until you see the Finish button.
11. Change the Name to CUSTOMER and select Preview the Query.
12. Click Finish. A preview screen with the records in the database should
appear.
13. Click OK to create the dataview for the CIF.
14. Create another dataview for LOOKUP and name it as CUSTOMERTYPE.
Set a search criteria for LookupCode = CT and LangType = 001.
1.
2.
3.
4.
5.

II.

Linking the Dataviews


At this stage, you have two dataviews for the CUSTOMER and
CUSTOMERTYPE. You will need to create a master-detail relationship
between these two tables.
Click on the field CUSTOMERTYPE.LOOKUPCODE and drag it towards
CUSTOMER.Type, a connecting line between the two fields should
appear.
2. Double click on the connecting line to access the Link dialog.
3. Click on option 2.
4. Click on the Ok button.
1.

III.

Report Design
The design workspace is the environment in which you will build the
layout of the report. By default, this workspace shows three sections
which are the Header band, Detail band and Footer band. You will also
find toolbars containing objects which are similar with that of which the
Microsoft Office is using. You must get familiar with these objects
especially with those you will use to display the information from the
dataviews.
You can start working on this by selecting the Design tab.

22-2

Session 22: Attachment 1

Selecting the Main Dataview


1. Select the Report | Data to access the Data dialog.
2. Locate the CUSTOMER and click on it.
3. Click the OK button.
The Header band
1. Locate the label icon
and click on it. This icon represents a Label
component.
2. Click on the white space of the Header band to create a Label.
3.
On the upper left corner of the tab page, locate the edit box that says
Label1 and change this caption to CID Number.
4.
Create two more labels in the Header band and set the captions as
Customer Name and Customer Type respectively.
The Detail band
1. Locate the icon
and click on it. This icon represents a DBText
component.
2. Click on the white space of the Detail band just below to create a
DBText.
3.
Locate the edit box that says CUSTOMER, and click on the edit box
next to it. It will open a dropdown list for the fields in CUSTOMER
table.
4. Search for the field CID and select it.
5.
Create two more DBText for the CUSTOMER.Name and
CUSTOMERTYPE.FullDesc.
The Footer band
1.

Create a label on the Footer band and change the caption to Total
Number of Customers.

2. Locate the icon


and click on it.
3. Click on the white space of the Footer band to create a DBCalc.
4.
Right click on the DBCalc object and select Calculations, this will
open a dialog box.
5. On the Calc Type dropdown list, select Count.
6. Click OK to close the dialog.
1. Preview
2.

Click on the Preview tab and locate the icon


Page-Width.

to change the view to

3. Click on the icon

or

to move the page forward.

4. Click on the icon

or

to move the page back.

1.

Saving the Report

22-3

Session 22: Attachment 1

After you have set all the layouts and proper alignments of your report, you
can go back to the Design Tab page, select File | Save As and save the
report to a file.

22-4

Você também pode gostar