#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Custom format

I have 2 rows of numbers: 2, 3, 5, 4
and 4, 3, 4, 5
I want to format the numbers in second row to display in red, if it is
greater than the number in the first row (in same column), in blue, if it
less than, and in black if otherwise.
Please help. Thanks in advance.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9,101
Default Custom format

Use conditional formating. click on the 1st 4 in the 2nd row. In the Fomat
Menu select conditional formating

this assumes the data is in rows 1 & 2.

enter in condition 1
=IF(A1A2,TRUE,FALSE)
select format and in Pattern select red
Press OK

Select Add
enter condition 2
=IF(A1<A2,TRUE,FALSE)
select format and in Pattern select blue
Press OK

Select Add
enter condition 3
=IF(A1=A2,TRUE,FALSE)
select format and in Pattern select black
Press OK

Now you have to copy the conditional format. with the 1st 4 on row 2
highlighted select the paint brush on the tool bar. Now highlight columns 2
- 4. The conditional formating should be on all cells on row 2 columns 2 - 4.
"m.sparks" wrote:

I have 2 rows of numbers: 2, 3, 5, 4
and 4, 3, 4, 5
I want to format the numbers in second row to display in red, if it is
greater than the number in the first row (in same column), in blue, if it
less than, and in black if otherwise.
Please help. Thanks in advance.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Custom format

You can do it simpler than that.

If you are using "Formula is", you don't need the =IF(...,TRUE,FALSE)
construct; all you need is =A2A1

Another option is "Cell Value is" "greater than" =A1

And you don't need to go through the format paint routine at the end if you
select cells A2-D2 in the beginning and have cell A2 as the active cell
while you set up the conditional formatting.
--
David Biddulph

"Joel" wrote in message
...
Use conditional formating. click on the 1st 4 in the 2nd row. In the
Fomat
Menu select conditional formating

this assumes the data is in rows 1 & 2.

enter in condition 1
=IF(A1A2,TRUE,FALSE)
select format and in Pattern select red
Press OK

Select Add
enter condition 2
=IF(A1<A2,TRUE,FALSE)
select format and in Pattern select blue
Press OK

Select Add
enter condition 3
=IF(A1=A2,TRUE,FALSE)
select format and in Pattern select black
Press OK

Now you have to copy the conditional format. with the 1st 4 on row 2
highlighted select the paint brush on the tool bar. Now highlight columns
2
- 4. The conditional formating should be on all cells on row 2 columns
2 - 4.


"m.sparks" wrote:

I have 2 rows of numbers: 2, 3, 5, 4
and 4, 3, 4, 5
I want to format the numbers in second row to display in red, if it is
greater than the number in the first row (in same column), in blue, if it
less than, and in black if otherwise.
Please help. Thanks in advance.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom Cell format to mimic time format [email protected] Excel Discussion (Misc queries) 6 November 7th 06 09:17 PM
custom format or conditional format? Anita Excel Discussion (Misc queries) 1 October 24th 06 06:41 PM
how do I add phone number format as a permanent custom format? frustratedagain Excel Discussion (Misc queries) 3 February 4th 06 03:52 AM
Format a cell with a custom number format Armor Excel Worksheet Functions 4 January 29th 06 11:25 PM
custom format! via135 Excel Discussion (Misc queries) 2 January 7th 06 08:02 PM


All times are GMT +1. The time now is 07:37 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"