Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 20
Default Conditional Formatting and Cell Color

Here is my issue:
I want to color multiple cells based on certain criteria. For example,
I will select all cells F1:F12 and if the percentage in each cell is
less than the percentage in the same row (different column), color that
cell red. If greater, color it yellow. If =, color it white. I used
conditional formatting, and it is screwing up the colors based on what
I'm sure is my crappy logic. Please revise if you can. Thanks,


=IF((F12C12), 1, 0) - Formatting color chosen is yellow
=IF((F12<C12), 1, 0) - Formatting color chosen is red
=IF((F12=C12), 1, 0) - Formatting color chosen is white

But the colors are not displaying correctly for the cells where the
values are =. I can elaborate if necessary, I'm assuming its the if
loop that is the prob. Thanks,
Steve

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,069
Default Conditional Formatting and Cell Color

For conditional formatting, you just need formulas that return TRUE or FALSE.
Try these:

=(F12C12)
=(F12<C12)
=(F12=C12)

Hope this helps,

Hutch

"nemadrias" wrote:

Here is my issue:
I want to color multiple cells based on certain criteria. For example,
I will select all cells F1:F12 and if the percentage in each cell is
less than the percentage in the same row (different column), color that
cell red. If greater, color it yellow. If =, color it white. I used
conditional formatting, and it is screwing up the colors based on what
I'm sure is my crappy logic. Please revise if you can. Thanks,


=IF((F12C12), 1, 0) - Formatting color chosen is yellow
=IF((F12<C12), 1, 0) - Formatting color chosen is red
=IF((F12=C12), 1, 0) - Formatting color chosen is white

But the colors are not displaying correctly for the cells where the
values are =. I can elaborate if necessary, I'm assuming its the if
loop that is the prob. Thanks,
Steve


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Conditional Formatting and Cell Color


If your conditional formatting doesn't give the correct result when C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=565769

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 20
Default Conditional Formatting and Cell Color

Thanks! I'm almost positive you hit it on the head there with the
rounding. For example, cell C3 is actually 15.2, but as a percentage
it shows up as 15% in the cell. When I apply the round to the cell
=ROUND(C3,0) it rounds .152 to 0. What I want is for it to round it to
15%. Do you know how to do this? Thanks so much,
Steve



daddylonglegs wrote:
If your conditional formatting doesn't give the correct result when C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=565769


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,593
Default Conditional Formatting and Cell Color

=ROUND(C3,2)

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nemadrias" wrote in message
ups.com...
Thanks! I'm almost positive you hit it on the head there with the
rounding. For example, cell C3 is actually 15.2, but as a percentage
it shows up as 15% in the cell. When I apply the round to the cell
=ROUND(C3,0) it rounds .152 to 0. What I want is for it to round it to
15%. Do you know how to do this? Thanks so much,
Steve



daddylonglegs wrote:
If your conditional formatting doesn't give the correct result when C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile:

http://www.excelforum.com/member.php...o&userid=30486
View this thread:

http://www.excelforum.com/showthread...hreadid=565769





  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 20
Default Conditional Formatting and Cell Color

Bob -
How can I round all of the cells in that column without creating a
circular reference? I don't want to add a column for the rounded
percentages, just want to round them all to the percent. =ROUND(C3,2)
creates a circular reference obviously if I would paste it in C3. Any
suggestions? Thanks,
Steve


Bob Phillips wrote:
=ROUND(C3,2)

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nemadrias" wrote in message
ups.com...
Thanks! I'm almost positive you hit it on the head there with the
rounding. For example, cell C3 is actually 15.2, but as a percentage
it shows up as 15% in the cell. When I apply the round to the cell
=ROUND(C3,0) it rounds .152 to 0. What I want is for it to round it to
15%. Do you know how to do this? Thanks so much,
Steve



daddylonglegs wrote:
If your conditional formatting doesn't give the correct result when C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile:

http://www.excelforum.com/member.php...o&userid=30486
View this thread:

http://www.excelforum.com/showthread...hreadid=565769


  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Conditional Formatting and Cell Color

Do you have a formula already in column C to calculate the percentage?
If so, you can change it to:

=ROUND(your_existing_formula,2)

and copy this down.

Alternatively, incorporate the ROUND function in the conditional
formatting formulae.

Hope this helps.

Pete

nemadrias wrote:
Bob -
How can I round all of the cells in that column without creating a
circular reference? I don't want to add a column for the rounded
percentages, just want to round them all to the percent. =ROUND(C3,2)
creates a circular reference obviously if I would paste it in C3. Any
suggestions? Thanks,
Steve


Bob Phillips wrote:
=ROUND(C3,2)

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nemadrias" wrote in message
ups.com...
Thanks! I'm almost positive you hit it on the head there with the
rounding. For example, cell C3 is actually 15.2, but as a percentage
it shows up as 15% in the cell. When I apply the round to the cell
=ROUND(C3,0) it rounds .152 to 0. What I want is for it to round it to
15%. Do you know how to do this? Thanks so much,
Steve



daddylonglegs wrote:
If your conditional formatting doesn't give the correct result when C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile:

http://www.excelforum.com/member.php...o&userid=30486
View this thread:

http://www.excelforum.com/showthread...hreadid=565769


  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,593
Default Conditional Formatting and Cell Color

With VBA?

For Each cell In selection
cell.Value = Round(cell.value,2)
Next cell

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nemadrias" wrote in message
oups.com...
Bob -
How can I round all of the cells in that column without creating a
circular reference? I don't want to add a column for the rounded
percentages, just want to round them all to the percent. =ROUND(C3,2)
creates a circular reference obviously if I would paste it in C3. Any
suggestions? Thanks,
Steve


Bob Phillips wrote:
=ROUND(C3,2)

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nemadrias" wrote in message
ups.com...
Thanks! I'm almost positive you hit it on the head there with the
rounding. For example, cell C3 is actually 15.2, but as a percentage
it shows up as 15% in the cell. When I apply the round to the cell
=ROUND(C3,0) it rounds .152 to 0. What I want is for it to round it

to
15%. Do you know how to do this? Thanks so much,
Steve



daddylonglegs wrote:
If your conditional formatting doesn't give the correct result when

C12
and F12 are equal that's probably because the aren't EXACTLY equal.
e.g. if you only display without decimals then 16% could in reality

be
16.23%. You could use conditional formatting formulas like

=ROUND(C12,0)Round(F12,0)

=ROUND(C12,0)<Round(F12,0)

=ROUND(C12,0)=Round(F12,0)


--
daddylonglegs

------------------------------------------------------------------------
daddylonglegs's Profile:

http://www.excelforum.com/member.php...o&userid=30486
View this thread:

http://www.excelforum.com/showthread...hreadid=565769




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
Cell Formatting Conditional On Other Cells Fill Color? [email protected] Excel Worksheet Functions 1 April 5th 06 10:05 PM
Conditional Formatting to Test Value in Cell Carroll Excel Worksheet Functions 3 March 9th 06 07:38 PM
Cell color change without using conditional formatting Trese Excel Discussion (Misc queries) 2 August 26th 05 06:00 PM
Cell color based upon cell value My View Excel Discussion (Misc queries) 11 July 6th 05 03:59 AM
GET.CELL Biff Excel Worksheet Functions 2 November 24th 04 07:16 PM


All times are GMT +1. The time now is 12:09 AM.

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"