Choosing the field

B

Bruce

In a report, I want to be able to see if there is a value
in the Personal Fax field. If there is, I want to use it;
if there is not, I want to use the Main Fax field. I have
tried =IIf(IsNull([Personal Fax]),[Main Fax],[Personal
Fax]. I have also tried a variant with Not IsNull. If
instead of the [Main Fax] field I use "text" it works, but
it does not work with the field name. What am I doing
wrong?
 
R

Rick Brandt

Bruce said:
In a report, I want to be able to see if there is a value
in the Personal Fax field. If there is, I want to use it;
if there is not, I want to use the Main Fax field. I have
tried =IIf(IsNull([Personal Fax]),[Main Fax],[Personal
Fax]. I have also tried a variant with Not IsNull. If
instead of the [Main Fax] field I use "text" it works, but
it does not work with the field name. What am I doing
wrong?

The name of the control isn't "Main Fax" by any chance is it? Controls
based on expressions cannot be named the same as any field used within that
expression.
 
B

Bruce

That was it. So simple now that I know. Thanks so much.
-----Original Message-----
In a report, I want to be able to see if there is a value
in the Personal Fax field. If there is, I want to use it;
if there is not, I want to use the Main Fax field. I have
tried =IIf(IsNull([Personal Fax]),[Main Fax],[Personal
Fax]. I have also tried a variant with Not IsNull. If
instead of the [Main Fax] field I use "text" it works, but
it does not work with the field name. What am I doing
wrong?

The name of the control isn't "Main Fax" by any chance is it? Controls
based on expressions cannot be named the same as any field used within that
expression.


--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com


.
 

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