Problem with exporting formatted access reports to RTF/excel format


Paul Le Sueur

Dear All,

I have created a report in Access97 which displays a large
number of dates in a tabular format, like this:

Item Date1 Date2 Date3 Date4 Date5
A 01/01/02 10/01/02 11/02/02 12/03/04 13/01/01
B 13/12/02 11/03/04 21/10/02 27/11/03 19/02/03
C 19/01/04 17/06/02 30/09/05 15/08/05 26/03/04
D 23/01/03 14/02/04 31/03/03 19/04/01 29/06/01
E 02/01/01 12/09/05 01/02/01 30/01/02 16/01/02

I have used the "Format" event (in VBA) of the detail section
(where the dates are printing) to set them to be underlined if
they are within a date range, like this:

Private Sub Detail_Format(Cancel As Integer, _
FormatCount As Integer)

If Date1.Value > CDate("1/1/2002") Then
Date1.FontUnderline = True
Date1.FontUnderline = False
End If
If Date2.Value > CDate("1/1/2002") Then
Date2.FontUnderline = True
Date2.FontUnderline = False
End If

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question