Access Query Conditional format

I have a field called commission rate in a query.  I would like to change the format color of the results.  If it returns 12% I want it to be green, 15% is Yellow and 18% is Purple.  (I don't really need those colors but want it be different.)  If any other results I want it just to plain.  Any suggestions?
cres1121Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
You cannot apply formatting in a query. You can create a Form that's based on your query, and then use the Conditional Formatting capabilities of the Form to do this (or a Report, if you'd prefer).

To do that, after creating your form open it in Design view and then click the Format ribbon item. Select the control you want to format and click the Conditional Formatting button on the ribbon.

See this article for more info on Conditional Formatting: https://support.office.com/en-sg/article/Change-the-appearance-of-a-control-by-using-conditional-formatting-6ba9e9fa-4347-4183-b335-44e43b05e22f
0
cres1121Author Commented:
Thank you for you time.. Unfortunately I need in it in the query because I think export it to and excel spreadsheet for others to do things on.  I know I can do it in excel but I didn't want to have to fuss a second time.   I will read thru the material.
0
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
Then your answer is "You can't do that" - as I mentioned above, you cannot format the query datasheet.

Even if you could format it, your formatting wouldn't carry over to your export - so it wouldn't do you any good to format it here. If it's going to land in Excel ultimately, then do your formatting there. You can use Excel automation to do that, or create an Excel workbook that has the formatting builtin, and then export your data to that Excel workbook.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Jeffrey CoachmanMIS LiasonCommented:
Not sure if this is what you need, ...

But you can create Datasheet View form, (based on the query)
Then you can do the conditional formatting in design view of this form.
So, you are actually formatting a Form, but it will look like the query, (in datasheet View)
sample
But Scott is also correct in that this formatting will not pass through to Excel...
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.