Integer field to show text
am 23.01.2008 20:38:13 von mcgrathml
Hi,
A customer has requested that if a integer field shows a 0 or is
null that it appears as 'ND" (or no data).
Not too sure whether this can be defined in the table design or can it
be done as an expression in a report?
All help gratefully received.
Michael
Re: Integer field to show text
am 23.01.2008 22:45:15 von fredg
On Wed, 23 Jan 2008 11:38:13 -0800 (PST), mcgrathml@gmail.com wrote:
> Hi,
>
> A customer has requested that if a integer field shows a 0 or is
> null that it appears as 'ND" (or no data).
>
> Not too sure whether this can be defined in the table design or can it
> be done as an expression in a report?
>
> All help gratefully received.
>
> Michael
It has to be done on the report.
Here are 2 ways.
Use an expression in the report.
Using an unbound text control:
=IIf(IsNull([FieldName]) or [FieldName]= 0,"ND",[FieldName])
or ..
Use a control bound to the field.
Set the control's Format property to:
#;-#;"ND";"ND"
For more information on why this works see Access help on
Format property + Number and Currency datatype
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail