Setting variable forecolors in acViewReport

User avatar
kenrav
NewLounger
Posts: 10
Joined: 20 Jul 2012, 22:17

Setting variable forecolors in acViewReport

Post by kenrav »

In acViewPreview, I can set the forecolor of fields based upon different values in Detail_Format. For example:

If [Comp_Date_5].Text < "240" Then
[Comp_Date_5].ForeColor = vbRed
End If

Unfortunately, Detail_Format doesn't seem to get called if acViewReport is used and I can't seem to call it without getting an "Argument not Optional error. Any ideas?

Thanks!

Kenrav

User avatar
HansV
Administrator
Posts: 78632
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Setting variable forecolors in acViewReport

Post by HansV »

Welcome back!

I'd disable Report View and only allow users to view the report in Print Preview.
Report View is kind of useless in my experience, since - as you have found - most events don't occur.
Best wishes,
Hans

User avatar
kenrav
NewLounger
Posts: 10
Joined: 20 Jul 2012, 22:17

Re: Setting variable forecolors in acViewReport

Post by kenrav »

Thanks for the welcome. I'm sure you'll be seeing more of me now. Also, thanks for your quick reply - I will stick with Print Preview.

Ken