Adding Style to Reports

<< Click to Display Table of Contents >>

Navigation:  Other Topics > Smart Access 1996-2006 > Jun-2003 >

Adding Style to Reports

Dave Gannon and Nich Mann


Tired of creating boring reports? Dave Gannon and Nich

Mann show you how to add some visual pizzazz.


IF, as we have, you’ve been working with Access for

eight years, you get fed up with producing the same

tired looking reports. You know the ones—they’re

very business-like and feature horizontal double-lines

everywhere to separate data rows (yawn). You create

reports like this because your users want to see reports

like this—it’s a very professional look. But, as developers,

we know that other styles can be created that look just as

effective. In this article we’ll show you how to add an

interesting visual to your reports. You’ll also learn how to

use one of Access’s graphical functions (in depth!) and get

a routine that will automate the whole process for you.

Spicing up your reports can be as simple as adding this

routine to your project and calling it.


Figure 1 shows the kind of graphics that we’ve been

adding to our reports.


There are several ways in which we could have

achieved our objective. One method is to use graphics

embedded in the report. We decided against this,

however, as graphics either rely on external files

(dangerous if the file gets moved) or are pasted directly

onto reports (which can bloat your database). We decided

to create our graphics by drawing directly onto the report

using the Line() and Circle() methods.


Drawing circles and arcs

Drawing a circle, arc, or pie slice is pretty straightforward,

once you know how. The key is to understand how the

Circle statement draws these objects. The statement is

defined as:


object.Circle [Step](x, y), radius[, [color][,

[start][, [end][, aspect]]]]


The parameters of the Circle method are:

x and y represent the center of the circle or arc.

radius is the radius length.

color is the color that will be used to draw the arc.

start and end are the start angle and end angle (in

radians) of the arc.

aspect determines whether a circle or elliptical shape

is drawn.

Microsoft Help also mentions that the Circle


Read more in the pdf here Adding Style to Reports


Figure 1