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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Format colors for negative and positive in union query

Status
Not open for further replies.

LonnieJohnson

Programmer
Joined
Apr 16, 2001
Messages
2,628
Location
US
I have a union query where one of the columns is a dollar amount. How do I make the column show the data as red for negative and blue for positive amounts?

Thanks in advance!

ProDev, MS Access Applications
Visit me at ==>
May God bless you beyond your imagination!!!
 
Where? A single form? A continuous form? You can do quite a bit with the Format function.
 
You can set the Format property to display numbers differently depending on if they are Positive, Negative, Zero, or Null. Check Help on "format numeric". This even works with datasheet view of a form.

Format: 0.00[Green];(0.00)[Red];0.00[Black];"na"

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
It is actually not in a form at all. It is the result set from the union query.

Are you saying that it has to be in a form before I can play with the colors?

Thanks.

ProDev, MS Access Applications
Visit me at ==>
May God bless you beyond your imagination!!!
 
As far as I know, you need a form for this kind of control.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top