How to Draw Line on Last Record

  • Thread starter Thread starter DOYLE60
  • Start date Start date
D

DOYLE60

On several reports, I'm using the following code to draw a line every 5
records.

Me.Line110.Visible = (Me!CountThem Mod 5 = 0)

I just designed a new report that is going to need to do the above but also
draw a line after the last record. How do I edit the above to do that? Thanks,

Matt
 
I would try the following.

Me.Line110.Visible = (Me!CountThem Mod 5 = 0 or Me!CountThem = Count(*))
 
Thanks John. But the expression below does not go in. It has problems with
the *. I tried Count() and some other things but could not fix it.

Me.Line110.Visible = (Me!CountThem Mod 5 = 0 or Me!CountThem = Count(*))

Thanks again,

Matt
 
Ok then let's try adding an invisible control to the report. I would put that
in the Report Header so that it only gets called once.

Put a control in the header and name it TotalCount
Set its control source to =Count(*)

Then change the line to

Me.Line110.Visible = (Me!CountThem Mod 5 = 0 or Me!CountThem = Me!TotalCount)
 
Back
Top