CJ said:
How can I use conditional formatting to format a duplicate date in a
report? I need the duplicates to show up but I would like them to be
obvious.
Do you mean duplicates between records? i.e. if this record has the same
date as the one before it, than highlight the fact?
Conditional Formatting can't compare across records, so let's explore
alternatives, assuming the report is sorted by date (so duplicates are
contiguous.)
You could use code in the section's events (Print to record the previous
date, and Format to flag the duplicate if it's the same.) This has several
disadvantages: it's slow, unreliable across page breaks (where you don't
print all report pages), and doesn't work at in in Report or Layout view.
A better approach would be to use a combination of the HideDuplicates and
IsVisible properties. HideDuplicates will hide the date if it's the same as
the one before. You can then add another text box bound to an expression
that tests the IsVisible property of the date box. If IsVisible is false,
then show the date in whatever color/bolding you want to flag it as a
duplicate.
If that approach is not familiar, here's some more info on working with
them:
http://allenbrowne.com/casu-21.html
Although the article is for a different purpose, it illustrates the idea.