Calculated Field - Don't Always Display

  • Thread starter Thread starter Kirstie Adam
  • Start date Start date
K

Kirstie Adam

All,

I have a report which has a calculated text field.
There are 3 things this field will be "A", "B", "C".

It ends up looking like this: (or similar)

A - text blah blah
A - text 2 blah blah
A - text 3 blah blah
B - text 4 blah blah
B - text 5 blah blah
C - text 6 blah blah
C - text 7 blah blah
C - text 8 blah blah

I want to only show the top value eg.

A - text blah blah
text 2 blah blah
text 3 blah blah
B - text 4 blah blah
text 5 blah blah
C - text 6 blah blah
text 7 blah blah
text 8 blah blah

Can anyone help?

Kirstie
 
In report design view, right-click the text box, and choose Properties.
Set HideDuplicates to Yes.
 
Allen,

Unfortunately, that doesn't work. I think its because they are not
individual RECORDS, just text boxes that show one of three options,
depending on what another text box shows. There will always be 8 rows, and
they could be any combination of A's, B's and C's. But theye will never be
out of order (you wouldn't get an A after a C)

Do you have any other suggestions?

Kirstie

ps - I have used your website a lot, and find it very helpful. Thanks!
 
Is ok, got it to work using some code:


Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
If Me.act2 = act1 Then
Me.act2.ForeColor = vbWhite
Else

End If
End Sub


Kirstie
 
Rather than hardcoding the ForeColor property, it would be a
little cleaner to make the control visible or not as needed:

Me.act2.Visible = (Me.act2 = Me.act1)
--
Marsh
MVP [MS Access]
 
Marsh,

Thanks very much, that is much simpler. And works brilliantly.

Thanks,

Kirstie

Marshall Barton said:
Rather than hardcoding the ForeColor property, it would be a
little cleaner to make the control visible or not as needed:

Me.act2.Visible = (Me.act2 = Me.act1)
--
Marsh
MVP [MS Access]



Kirstie Adam said:
Is ok, got it to work using some code:


Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
If Me.act2 = act1 Then
Me.act2.ForeColor = vbWhite
Else

End If
End Sub
 
Back
Top