In my previous blog post I created a Crystal Report. Today I’m going to explain on how to design your Crystal Report. Below is the screen shot of the report that I created earlier.
First I will explain about the different sections of the report. As you can see in the screen shot there are 5 sections in the report.
- Report Header
- Page Header
- Details
- Report Footer
- Page Footer
Report Header
Objects that are placed in the Report Header section are printed only once, at the beginning of the report.
Page Header
Objects that are placed in this section are printed at the beginning of each new page.
Note: You cannot place charts or cross tabs in this section.
Details
Objects that are placed inside this section are printed with each new record.
Report Footer
Objects that are placed in this section are printed only once at the end of the report.
Page Footer
Objects that are place in this section are printed at the end of each page.
Now let’s design the report. First up I will include a company name for the report and the telephone no. You want the company name and the telephone no to be printed only once in the report. Therefore the best place to place these is the Report Header Section. Then it will only be printed once per report.
First right click on the Report Header tab and select Don’t Suppress.
If you want to add the company logo with the company name and the telephone no as an Image then just right click on the area between the Report Header and the Page Header tabs and the select Insert and then click on Picture. Then select your picture and place it In the Report Header.
In the Page header section you can add objects which you want to be printed in all the pages of the report. In this Report I’m only making the text Bold in the Headings.
I’m leaving the Details Section as it is but if you want to format it you can do it in the same way as above.
In the Report Footer Section you can add any object that needs to be printed at the end of each report. For an example I can place a formula to calculate the total Quantity of the items. (How to implement a formula will be explained in the next blog post.)
I have drawn a line by using a line object which can be found in the Tool Box.
Then in the Page Footer section I’m including the page no which is a special filed. It is automatically added to the Page Footer section at the time of report creation. So it will print the page no per page.
OK now when I run my application I’m seeing my newly designed report with the page no printed on the bottom of the report.
That’s it for this post. In the next post I will explain how to format the fields.








No comments:
Post a Comment