Monday, February 24, 2014

Controlling the Report Presentation - Changing the background color of a report

There are a number of different ways to specify CSS classes and I’ll discuss two different methods of modifying the report background color. Specifying the background on a report is accomplished by specifying the background-color style property.

The first method is to define a style for the HTML <body> tag. This will affect everything beneath the Body element without further ado.

BODY
{
   background-color : OldLace;
}

The second approach is to define a class (which always starts with a “.”)

.ReportStyle
{
   background-color : OldLace;
}

Add this class to your style sheet and specifically apply that class to the appropriate element in the report:

Figure 4.6: Attributes Panel after setting Report element Class attribute

Go ahead and make this assignment in your report definition. Note that the same style sheet and style class should be applied to any sub-report (i.e. the Chapter3SubReport).

No comments:

Post a Comment