background colour report dependi
The UK's Number 1 for Microsoft Office Training Add this page to your favourites/bookmarksBookmark page
 
View printable version of pagePrintable version
Plus One Google
Customer: Sign in
Delegate: Sign in
Trainer: Log in

Forum home » Delegate support and help forum » Microsoft Access Training and help » Background colour on report depending upon certain text in a fie

Background colour on report depending upon certain text in a fie

resolvedResolved · High Priority · Version 2007

replyReply Fri 19 Mar 2010, 20:10Delegate Kieran said...

Kieran has attended:
No courses

Background colour on report depending upon certain text in a fie

I am trying to work out how to make a background of a cell on a report a particular colour depending upon the input in one particular field.

An example of what I'm trying to do would be if I had a database listing peoples political party, and I wanted it to correspond: So people who are Labour would be red, Liberal Democrat would be Yellow, Conservative Blue, etc.

How do I do this?

For upcoming training course dates see: Pricing & availability

replyReply Mon 22 Mar 2010, 11:56Trainer Stephen said...

RE: Background colour on report depending upon certain text in a

Hi Kieran

Thanks for your question

can you clarify for me whether you are working in Excel or Access. You post mentions changing a cell colour but also refers to the contents of a field.

If you are working with excel, then we need to look at conditional formatting. if this is the case then i also need to know if you are using 2003 or 2007.

Thanks

Stephen

replyReply Mon 22 Mar 2010, 21:38 Edited on Mon 22 Mar 2010, 21:40Delegate Kieran said...

RE: Background colour on report depending upon certain text in a

Hi Stephen

It is Access 2007 I am using.

An example of what i am trying to do is I have a database, which lists requests, as well as submitted date, due date, completed date etc. I would like to somehow highlight in a report that this item is overdue, ideally by highlighting it in some way.

I hope this provides some clarification as to what I'm after.


Thanks for your help
K

replyReply Mon 29 Mar 2010, 15:21Trainer Stephen said...

RE: Background colour on report depending upon certain text in a

Hi Kieran

Thanks for the clarification.

It might be possible to use the conditional formatting tool in Access 2007. Open the form in design view and select the field to be formatted.
The conditional format tool is found in the Font group. Simply activate it and then select the criteria required as well as the formatting. In the example you give simply set the due date filed to less than and Date(). This should then change colour when the current date is after the due date.


Regards

Stephen

Mon 5 Apr 2010: Automatically marked as resolved.

 

Please browse our web site to find out more about
2000 access microsoft training and other Microsoft training courses.

Access tip:

Create a custom Close button on a Form

By default, Forms that you create in Access have a full set of control buttons, that is, a title bar with Minimize, Maximize and Close buttons in the top right-hand corner and a Control Menu in the top left-hand corner.



Sometimes Access needs to follow certain procedures or events as users close a Form (such as automatically opening another Form perhaps). So it is often a good habit to create a custom Close button on a Form for everyone to use, rather than the standard closing cross.



To create a custom Close button:

1) In Form Design View, draw a Command Button onto the Form.

2) Use the Command Button Wizard to select Form Operations under Categories, and Close Form under Actions.

3) Choose Finish.



Access then creates the button and code to close the form for you. You can add any extra code that needs to run as the Form closes to the same Close procedure.



However, the creation of a custom Close button is pointless if the closing X in the top right-hand corner of the Form remains active. To make the closing X inactive, open the Form Properties box then on the Format tab set the Close Button setting to No. This will grey out the closing X leaving it visible, but inactive.



View all Access hints and tips


Microsoft Certified Partner Accredited Training Provider: Institute of IT Training Institute of Leadership and Management - Certified Courses Security Seal verified by visa, mastercard securecard