Exploring the Format Editor Dialog Common Options


The previous exercises introduced the Format Editorthe dialog where the appearance of report fields and other report objects can be manipulated. Different Crystal Reports objects present different tabs within the Format Editor and each provides specific editing functionality for the underlying object types (such as Date and Time, Boolean, Hyperlink, and so on). The next few sections introduce the most commonly used tabs and underlying formatting options.

The Common Tab of the Format Editor

The Common tab of the Format Editor provides basic functionality for the majority of Crystal Reports' objects. The most commonly used formatting features accessed through this tab include the following:

  • Object Name Assigned by default, this name is referenced primarily for use with Report Part Viewing (that is, when specifying which report parts to view in a report parts viewer).

  • ToolTip Text Enables a text bubble to be displayed as the end user hovers over report fields. A common and powerful use of ToolTips is to provide the end users with a database-driven description of the involved field from an associated meta-data table. To see this functionality in Design and Preview tabs, the ToolTips option must be turned on under the Layout tab of the Options dialog, accessed under the File menu.

  • Read Only This option makes the selected report object read-only so that it can't be formatted. When this option is selected, all other choices in the Format Editor except Repeat on Horizontal Pages and Lock Position and Size become inactive.

  • Lock Position and Size This option locks the position of the selected report object so that it can't be moved or resized.

  • Suppress Enables the suppression of the selected object in the Preview tab and on any report printing. This option is often used with intermediary formula components that the end user is not intended to view or on fields that the user is meant to view only conditionally. The x+2 button is used to suppress (or display) the selected field based on certain data conditions being met (for example, show "ALERT" text object only if Shipping Date is five or more days after Order Date for a specified field).

  • Suppress If Duplicated This option enables the suppression of repeated field names in a report.

  • Can Grow Enables for variable length fields to grow vertically in the report and word wrap automatically. A maximum number of lines can be set with this option to control rogue or large data elements.

  • Text Rotation Enables the rotated display of the involved object by 90° or 270°. This feature is highlighted in Chapter 9.

  • Horizontal Alignment Provides the capability to align the data within an object either left, center, right, or both justified.

  • Display String This Custom String functionality enables the conditional formatting and display of field types (for example, number, currency, date, time, date and time, Boolean, string, running total, formulas, parameters, and so on) as a custom string (for example, displaying the number 1,500,000 as the custom string 1.5M). The following sample formula snippet highlights how this would work:

    Switch ( CurrentFieldValue > 1000000000, ToText(CurrentFieldValue/1000000000, 2) + "B", CurrentFieldValue > 1000000, ToText(CurrentFieldValue/1000000, 2) + "M", CurrentFieldValue > 1000, ToText(CurrentFieldValue/1000, 2) + "K", True, ToText(CurrentFieldValue, 2))

  • CSS Class Name Provides the capability for Crystal Reports to leverage existing CSS stylesheet classes when deployed in a web application or with BusinessObjects Enterprise.

  • Repeat on Horizontal Pages Introduced in version 10, this option enables the repetition of a report object that does not expand horizontally (such as text objects, field objects, OLE objects, charts, maps, lines, boxes, and so on) for each additional horizontal page that a cross-tab or OLAP grid might create as it expands horizontally.

  • Keep Object Together This option keeps an object on a single page. If there is enough room, the program prints the object on the current page. If there is not enough room, the program prints the object on the next page. This is clearly not possible with objects that span more than a single page.

  • Close Border on Page Break This functionality ensures that borders created on the object close at the bottom of any page and begin again as the object is continued on the next page. This provides for a much slicker-looking border format for your reports.

The Border Tab of the Format Editor

The Border tab of the Format Editor provides border, background, and drop-shadow formatting functionality for Crystal Report objects. The most commonly used formatting features accessed through this tab include the following:

  • Line Style drop-down boxes The Left, Right, Top, and Bottom drop-down boxes enable specification of the different types of supported borders (Single, Double, Dashed, or Dotted). For Basic borders, this functionality is more easily accessed through the Borders button on the Formatting toolbar.

  • Tight Horizontal This option specifies that a border tightly wraps around the involved object's contents and not the entire field as placed on the report (that is, no spaces are included within the border).

  • Drop Shadow This format prints a drop shadow to the right and below the specified object.

  • Border Color The color of the border and drop shadow is specified here through the drop-down box.

  • Background Color The background check box enables you to specify that a background be displayed for the given field. An additional drop-down box enables you to select the color for the background after the check box has been selected.

The Font Tab of the Format Editor

The Font tab of the Format Editor provides the capability to change the fonts, font size, and font style for text and data fields in your Crystal Reports. The most commonly used formatting features accessed through this tab include the following:

  • Font, Style, Size, and Color Enable the designer to specify a variety of available formatting fonts (such as Arial, Courier, Verdana, Times Roman, and so on), styles (such as Bold and Italics), sizes including manually entered 1/2 sizes and colors.

  • Strikeout and Underline Enable you to specify the selected formatting on the current report object.

  • Character Spacing Exactly Use this option to specify the space that each character in the selected font occupies. The value is defined as the distance in number of points measured from the start of one character to the start of the next. When the character spacing is edited, only the spacing between adjacent characters is changednot the actual font size of the characters. Using 0 enables the default font character spacing.

The Hyperlink Tab of the Format Editor

The Hyperlink tab is used to create hyperlinks to external websites, e-mail addresses, files, or other reports and report objects from report objects within the current report. These hyperlinks can be data-driven (that is, change on the data coming back from the database) and provide a rather intuitive method for integrating Crystal Reports into a business workflow. The helpful hint section of this tab provides in-place coaching for each type of hyperlink that is to be used. The most commonly used formatting features accessed through this tab include the following:

  • Website on the Internet Enables the specification of an external website with or without dynamic context-sensitive components of the URL driven from the database. An example of a context sensitive web address would be http://www.google.com/search?q= + {Customer.Customer Name} where the link would take the end user to a Google search page full of results based on the current value of the customer name.

  • E-mail address Enables you to add a link to an e-mail address that would need to be typed into the E-mail address text box or through the associated formula editor x+2 button.

  • File Enables the linked upon object to call a specified file and launch its associated application upon end-user activation of this link. Report designers can specify EXE files with command-line parameters through the Formula Editor accessed by the x+2 button.

  • Current Website or E-mail Field Value Creates a website or e-mail link to the underlying object on which the hyperlink is being created. The formatting of the data for the involved field must be correct (that is, a proper e-mail address or website URL).

  • Report Part Drilldown The Report Part Drilldown option lets you define a hyperlink so that the Report Part Viewer can emulate the drill-down functionality of Crystal Reports. The Report Part Viewer displays only destination objects; therefore, to make drill down work, you need to define a navigation path from a home object to one or more destination objects, all residing in the same report section. Initial Report Part specification for a given Crystal Report is set within the Report Options dialog accessed from the main File menu. The drill-down path is then set for each Report Part in the navigation path through this option. Not all Crystal Reports objects have this option available based on their report section location and their type of object.

  • Another Report Object This option enables the definition of a hyperlink to objects in the same or different reports. When defining a hyperlink path to a different report, that report must be managed in a BusinessObjects Enterprise environment. To specify report objects, they must be copied using the right-click Copy command from their source report and then pasted into the current object's Hyperlink tab using the Paste Link button.

Other Format Editor Tabs

The remaining tabs found in the Format Editor are dependent on the type of object selected in the involved Crystal Report. The other tabs that you find and some of the most common formatting options provided in each are as follows:

  • Paragraph tab Enables you to specify formatting for string/text fields including spacing, reading order, and horizontal alignment.

  • Numbers tab Enables detailed formatting on numbers and currency objects including the handling of zeros, decimal point specification, negative number formatting, rounding, and thousands separator specification. The Customize button enables access to the majority of these formatting features.

  • Date and Time tab Provides detailed formatting on dates, times, and datetime objects. Many default display options are available with a great deal of granularity provided through the Customize button.

  • Boolean tab Enables the selection of the format for the return values of Boolean field objects.

  • Box, Line, Rounding, Subreport, and Picture tabs Provide for granular level formatting of each of the involved Crystal Reports objects.




Crystal Reports XI(c) Official Guide
Crystal Reports XI Official Guide
ISBN: 0672329174
EAN: 2147483647
Year: N/A
Pages: 365

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net