Conditional formatting on a label

G

Guest

Hi there

I would like a field label on a report to be invisible when the field value
= 0. Is it possible to apply conditional formatting to the label or to set
the visible property to "no" with a bit of code? Would appreciate your help.

To be clear
when [cost1] = 0 I would like labelcost1 to be invisible on the report print
out.

Many thanks for your help

Jenny
 
A

Allen Browne

In report design view, right-click the label and choose:
Change To | Text Box.

Set the Control Source of this text box to:
=IIf([cost1]=0, Null, "Cost1:")
 
G

Guest

Thanks Allen

Really great to have posed a question with such a simple answer!

Allen Browne said:
In report design view, right-click the label and choose:
Change To | Text Box.

Set the Control Source of this text box to:
=IIf([cost1]=0, Null, "Cost1:")

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Jenny said:
Hi there

I would like a field label on a report to be invisible when the field
value
= 0. Is it possible to apply conditional formatting to the label or to
set
the visible property to "no" with a bit of code? Would appreciate your
help.

To be clear
when [cost1] = 0 I would like labelcost1 to be invisible on the report
print
out.

Many thanks for your help

Jenny
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top