ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Need Help (https://www.excelbanter.com/excel-worksheet-functions/64542-need-help.html)

Phxlatinoboi®

Need Help
 
I am using the following formula:

=IF(I9<0,(H9-I9)/I9,IF(H9<0,(G9-H9)/H9,IF(G9<0,(F9-G9)/G9,0)))

How can I get the results to show if negative to turn "red" and if positive
to be "black"?

Bob Phillips

Need Help
 
Look up conditional formatting in Help.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Phxlatinoboi®" wrote in message
...
I am using the following formula:

=IF(I9<0,(H9-I9)/I9,IF(H9<0,(G9-H9)/H9,IF(G9<0,(F9-G9)/G9,0)))

How can I get the results to show if negative to turn "red" and if

positive
to be "black"?




Phxlatinoboi®

Need Help
 
The results show up as a percentage.
"Bob Phillips" wrote:

Look up conditional formatting in Help.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Phxlatinoboi®" wrote in message
...
I am using the following formula:

=IF(I9<0,(H9-I9)/I9,IF(H9<0,(G9-H9)/H9,IF(G9<0,(F9-G9)/G9,0)))

How can I get the results to show if negative to turn "red" and if

positive
to be "black"?





John Michl

Need Help
 
An easier method than conditional formatting is to apply cell
formating. Select the cell, right click and select Format Cells
Numbers. The Number and Currency formats include several options for
handling negative numbers including red text, parenthesis, minus signs,
etc. Just choose the one you like from the list.

To get fancier, choose one that is close to what you like and select
OK. Then open the format cells dialog again but choose custom. You
can change colors, add text and do a variety of things to format the
result.

- John
www.JohnMichl.com


Phxlatinoboi®

Need Help
 
How would I write the custom code that if the results are negative to change
to red, but if not to stay as is?

"John Michl" wrote:

An easier method than conditional formatting is to apply cell
formating. Select the cell, right click and select Format Cells
Numbers. The Number and Currency formats include several options for
handling negative numbers including red text, parenthesis, minus signs,
etc. Just choose the one you like from the list.

To get fancier, choose one that is close to what you like and select
OK. Then open the format cells dialog again but choose custom. You
can change colors, add text and do a variety of things to format the
result.

- John
www.JohnMichl.com



John Michl

Need Help
 
If the results are a percentage, use Custom Format and enter this

0.00%;[Red]0.00%

- John



All times are GMT +1. The time now is 05:39 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com