suppressing a textbox in a report

G

Guest

Hello to you all again.
In a query I have the following field
Sel1: "Selinium " & [Selinium] & "mg/kg as sodium selenite"
in the report, which runs off the back of the query what I want to do is
show [Sel1] if there is a quantity in [Selinium] and supress it if it is
zero. while it is suppressed I want the report to continue with the rest of
the data without leaving a gap.

[selinium] is a double number.

Thanks again.
 
M

Marshall Barton

Middlemuir said:
Hello to you all again.
In a query I have the following field
Sel1: "Selinium " & [Selinium] & "mg/kg as sodium selenite"
in the report, which runs off the back of the query what I want to do is
show [Sel1] if there is a quantity in [Selinium] and supress it if it is
zero. while it is suppressed I want the report to continue with the rest of
the data without leaving a gap.

[selinium] is a double number.


I think I would do this in the report instead of the query.
you can get the desired result in a text box by using an
expression like:

=IIf(Selinium=0, Null, "Selinium " & [Selinium] & "mg/kg
as sodium selenite")

and set the text box's (and its section's) CanShrink
property to Yes.

If you really want to do this in the query, use a similar
expression.
 

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