[AccessD] Add "Green Bar" effect to your Access Reports

Jim Dettman jimdettman at earthlink.net
Thu Sep 11 16:35:56 CDT 2003


That should be modified a bit.  If the report has grouping and certain
options selected, the detail section may get formatted more then once.
Depending on the number of times Access would retreat up the page, you might
end up with two lines with the same color.  So it should be done like this:

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

  If FormatCount = 1 then
    If Me.Detail.BackColor = vbWhite Then
      Me.Detail.BackColor = vbGreen
    Else
      Me.Detail.BackColor = vbWhite
    End If
  End If

End Sub



Jim Dettman
President,
Online Computer Services of WNY, Inc.
(315) 699-3443
jimdettman at earthlink.net

  -----Original Message-----
  From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Lonnie Johnson
  Sent: Thursday, September 11, 2003 4:38 PM
  To: 'MS-ACCESS-L at lists.missouri.edu'; AccessDevelopers; ms_access; AccessD
solving'
  Subject: [AccessD] Add "Green Bar" effect to your Access Reports


  This will give a green bar effect on a report. Every other line green. You
may want to play around with the numeric color expressions if you don't like
the loud green you get from vbGreen. Just a tip...


  Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
  If Me.Detail.BackColor = vbWhite Then
      Me.Detail.BackColor = vbGreen
  Else
      Me.Detail.BackColor = vbWhite
  End If
  End Sub






  Lonnie Johnson
  ProDev, Professional Development of MS Access Databases
  Visit me at ==> http://www.prodev.us








----------------------------------------------------------------------------
--
  Do you Yahoo!?
  Yahoo! SiteBuilder - Free, easy-to-use web site design software
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030911/552fccca/attachment-0001.html>


More information about the AccessD mailing list