Expression Builder

  • Thread starter Thread starter sara100815
  • Start date Start date
S

sara100815

I'm running a report which contains a lot of currency
fields in each record. If an entry isn't made in a record
Access automatically enters the value as "£0.00". I want
it to just be black, or for value's >0 to be bold. I
can't quite get the expression right. what should I do?
 
Sara,

No, Access does not "automatically enter the value as '£0.00'". It
means the data in the query that the report is based on is returning 0.
This may well be because the fields in question have their Default
Value set to 0 in either the table design or the data entry forms.

There are a number of possible approaches, and the best one would depend
on the actual details of your project. You could try removing the
default value for the fields (and running an Update Query to remove the
0 values from the existing records). You could use calculated fields in
the report's underlying query, in the place of the existing fields,
using syntax such as...
RealMoney: IIf([YourCurrencyField]=0,Null,[YourCurrencyField])
You could set the Format property of the textboxes on the report to
something like:
£#,##0.00;(£#,##0.00);"";""
Or, you could use Conditional Formatting on the textboxes, for Field
Value equal to 0 set the forecolor to white.

You can also use Conditional Formatting to set up for Bold font for
amounts > 0. Conditional Formatting is found under the Format menu in
the report design view.
 
Back
Top