Introducing the Crystal Reports Designer

This chapter takes you through the required steps to create your own basic reports in the Crystal Report Designer. After you've installed the Crystal Reports V.10 Designer, you are ready to open it and familiarize yourself with the environment. This section briefly introduces the following components of the application interface:

If you have already registered your installation, you should be presented with the Welcome to Crystal Reports screen shown in Figure 1.1. This screen provides quick access to existing Crystal Reports files while also enabling you to begin designing new reports via the Report Expert Wizard or from a blank report template.

Figure 1.1. The Welcome screen provides quick access to existing Crystal Reports files as well as the Report Expert Wizard.

 

Crystal Report Sections

From the Welcome dialog window, select Using the Report Wizard (listed below Create a New Crystal Report Document) and then click OK. You should see the Crystal Report Gallery dialog. Select As a Blank Report and click OK. At this point, you'll see a window labeled Data Explorer; click Cancel. If the Field Explorer window is also displayed, click Close.

You are presented with a blank report template that is divided into numerous report sections. As Figure 1.2 illustrates, report sections are identified by name on the left side of the design area. These sections segment the Crystal Reports design environment into logical areas to facilitate more intuitive report creationthese include the Report Header, Page Header, Details, Report Footer, and Page Footer sections. Each of these sections has unique properties and printing characteristics that you can modify. When creating reports, you place objects (such as data fields) into the various sections according to report requirements. If a report object such as an image is placed in the Report Header section, the image displays and prints only once per report, on the first page. If the same image is placed in the Page Header section, the image then displays and prints once per page. The same holds true for custom sections, such as Group Headers and Group Footers. The Details section implies that whatever is placed in this section displays and prints once for each and every row retrieved from the data source.

Figure 1.2. Report sections provide an intuitive way to create and organize your data when designing reports.

NOTE

Although Crystal Reports is commonly used for Web reporting initiatives, the design environment is built on a paper metaphor with pages as a concept to facilitate the presentation of information.

Report sections can contain a variety of different object types, including database fields, text, pictures, charts, and map objects. Additional objects, such as formula and subreport objects, are also positioned within report sections and are covered later in the book in greater detail.

The Section Expert is used to view or modify the properties of the report sections. To access the Section Expert, perform one of the following actions:

NOTE

When designing reports, you should consider the following items when working with report sections:

Crystal Reports also provides some more advanced section formatting options, reviewed later in the book, such as underlaying and suppressing sections based on certain criteria (formulas). These features are accessible from the Section Expert dialog.

Using Toolbars and Menus

Toolbars are the graphical icon bars at the top of the Crystal Reports application environment, containing various buttons that you can click to activate the most frequently used application commands. Toolbars act as shortcuts to access commonly used functions of the design application, and you can enable or disable them to appear or disappear at the top of the application area by selecting Toolbars from the View menu, which is located in the upper-most area of the application. As Figure 1.3 shows, there are four main toolbars that you can use within the Crystal Reports design environment:

Figure 1.3. The Four Crystal Reports Design Toolbars provide quick and easy access to commonly used application commands during report design.

NOTE

ToolTips are pop-up descriptions that appear when your cursor rests over any of the toolbar buttons. ToolTips are enabled by default. To disable ToolTips on your toolbars, deselect the Show ToolTips check box from within the Toolbars dialog.

In much the same way that the toolbars offer quick and easy access to commonly used commands, the menu items at the top of the application environment provide listings to virtually all the application functions available in Crystal Reports. The menu items act as shortcuts to all the commands within the design application, and they include the following items:

Report Design Explorers

Several report design explorers, intended to streamline the report design process, compose another key component to Crystal Reports 10. The design explorers are application tools that greatly enhance a report designer's efficiency while working with reports. They are design tools you will use in building reports throughout the remainder of the book.

The report design explorers are dialog windows that display various objects relevant to the report in a hierarchical tree view facilitating quick access to and formatting of each respective object and its properties. The explorers enable you to easily locate and navigate to specific report objects, such as the report header or a corporate logo image, to customize the object for design purposes. All the objects included in a report (report sections, groups, database fields, formulas, parameters, images, charts, and so on) are organized and displayed within one of the design explorers. There are three distinct explorers:

NOTE

It is important to emphasize that with Version 10, the centralized Crystal Repository is only available for use with Crystal Enterprise. See Chapter 18, "Crystal Reports Semantic LayerBusiness Views," for more details on this topic.

 

Locating and Using the Report Design Explorers

Each of the explorer dialogs can be docked in place or used in a free-floating state. By default, the Report and Field Explorers appear docked on the right side of the report design environment. However, you can manually dock each of them in other locations if you prefer. The explorers can also be used in free-floating mode, in which case each of the explorer dialog windows can be dragged to any location within the report design environment and float in place until you either close or reposition them. To view each of the report design explorers, click the View menu and select each desired explorer individually, as shown in Figure 1.4.

Figure 1.4. By default, the design explorers are docked on the right side of the report designer application but can be moved about and toggled on and off.

TIP

To save space in the design environment, the individual explorers can be dragged on top of each other and provide their functionality through respective tabs in a single dialog. This is the default position for the Field and Report Explorer in a fresh install but note in Figure 1.4 how the Report Explorer has been dragged into its own dialog with the Repository Explorer exposing itself through a tab in that same dialog.

The report design explorers create an intuitive way for report designers to add and format report objects quickly while constructing reports. As you progress through the remainder of the book, you will be using these explorers on a regular basis, so it's important that you understand the basics of these application features.

Категории