Grey Rows

  • Thread starter Thread starter Eric
  • Start date Start date
E

Eric

Somewhere I have seen instructions on how to make
alternate rows on a report grey like a spreadsheet.
Anyone know where these might be? I have searched the MS
Knowledge Base but no luck.
 
-----Original Message-----
Somewhere I have seen instructions on how to make
alternate rows on a report grey like a spreadsheet.
Anyone know where these might be? I have searched the MS
Knowledge Base but no luck.
.
Hello,

I use this feature in some of my reports.

Insert the following code in "Detail Section" ->
Event "On Format" in the report design:

Private Sub Detail_Format(Cancel As Integer, FormatCount
As Integer)
' white: 16777215
' light gray: 12632256
' dark gray: 8421504

Const clngCol1 = 16777215 'whithe
Const clngCol2 = 12632256 'light gray

If Me.Detail.BackColor = clngCol1 Then
Me.Detail.BackColor = clngCol2 'from whithe
to light gray
Else
Me.Detail.BackColor = clngCol1
End If
End Sub

Hope that helps.
ug
 
Thanks for your very detailed response
-----Original Message-----

Hello,

I use this feature in some of my reports.

Insert the following code in "Detail Section" ->
Event "On Format" in the report design:

Private Sub Detail_Format(Cancel As Integer, FormatCount
As Integer)
' white: 16777215
' light gray: 12632256
' dark gray: 8421504

Const clngCol1 = 16777215 'whithe
Const clngCol2 = 12632256 'light gray

If Me.Detail.BackColor = clngCol1 Then
Me.Detail.BackColor = clngCol2 'from whithe
to light gray
Else
Me.Detail.BackColor = clngCol1
End If
End Sub

Hope that helps.
ug
.
 
Back
Top