Conditional change to a field in a printed detail line

G

Goldar

My table contains group of account records that contain Account number,
Account description, Sub Account description and Sequence number. I want to
be able to change the detail printed line so that the Sub Account field
contains "(No sub accounts exist" whenever an Account group contains only one
record ([Sub Account] is null). If more that one record exists in the group,
I want the Sub Account field to contain the Sub Account description ([Sub
Account]). I'm not sure how to proceed.

Thanks...
 
R

Rob Parker

The simplest method would be to set the expression in the control to:
=Nz([Sub Account],"(No sub accounts exist)")

The control itself must not be named "Sub Account" (which is likely to be
the case if you've not changed it when building the report).

HTH,

Rob
 
K

Kate

I have a similar problem but with an extra twist. If the first field is
empty, I want to examine another field in the record to check for a Yes/No
value. If the value in the second field is No, I want to print "N/A" on the
report. If the value in the second field is Yes, I want to print nothing.
If the original field is not empty, I want to print it's value (which is
numerical).

Any suggestions?


Rob Parker said:
The simplest method would be to set the expression in the control to:
=Nz([Sub Account],"(No sub accounts exist)")

The control itself must not be named "Sub Account" (which is likely to be
the case if you've not changed it when building the report).

HTH,

Rob

Goldar said:
My table contains group of account records that contain Account number,
Account description, Sub Account description and Sequence number. I want
to
be able to change the detail printed line so that the Sub Account field
contains "(No sub accounts exist" whenever an Account group contains only
one
record ([Sub Account] is null). If more that one record exists in the
group,
I want the Sub Account field to contain the Sub Account description ([Sub
Account]). I'm not sure how to proceed.

Thanks...

.
 

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