Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to bold a font based on a value in a report

Status
Not open for further replies.

MJD1

Technical User
Jul 18, 2003
134
CA
Hi all,

This seems to be an easy task, but somehow I can't accomplish it.

I have several Month text fields (feb, mar, apr...) in a report that show a value based on a query. I would like the font of the value to show in Bold if the value is less than 85.

this is the code I tried, but doesnt work:

If Me![Feb] < &quot;85.00&quot; Then
Me![Feb].FontBold = True

Else
Me![Feb].FontBold = False
End If

Any help is appreciated.

thanks
martin
 
One way of changing the font is to highlight the field, go to Format on the Menu Bar and select Conditional Formating
 
thanks. when I go to format on the menu bar, Conditional formatting is not an option. should it make a difference, I am using access 97.

 
Conditional Formatting was added in Access 2000.
Do you get an error message when you run your code, or does it simply do nothing?

---------------------------------------
The customer may not always be right, but the customer is always the customer.
 
One more question. Is the code you list in the section of your report you are trying to affect? For example, if your fields are in the detail section, is your code in the
On Format event of the detail section?

---------------------------------------
The customer may not always be right, but the customer is always the customer.
 
I must have been realllly tired. As you suggested, I looked at which section i had put in the code.....and realized it was in the wrong section.

Thanks a million for pointing that out to me. I guess i had been looking at it too long.

Works great now. I even went with backgroud and foreground color change.

Your help was very much appreciated.

thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top