# formula - conditional - in EXCEL

Discussion in 'Business Applications' started by shortcut, Nov 3, 2003.

Not open for further replies.
1. Running EXCEL in ME on a HP8260. I put a formula in a cell and it works just fine. If the result is between -25% and -100% I want to print a red XXX.

The formula in cell C9 is (A9-B9)/B9*100

How can I make it print the correct answer except if the result is between -25% and -100%? and then print RED XXX's?

I have been all over the IF function and no help.

Ideas?

Thanks,
shortcut

2. Try this forumula:

=IF(((A9-B9)/B9*100)< -0.25, "XXX",((A9-B9)/B9*100))

Then you can apply conditional formatting using "Format" "Conditional Formatting" on the menubar.
Make Cell Value Equal To XXX, then click on the Format button, then the Color button on the Font tab. Change the color to red.

3. just a wee little whale change:

this:
=IF(((A9-B9)/B9*100)< -25, "XXX",((A9-B9)/B9*100))

or this:
=IF(((A9-B9)/B9)< -0.25, "XXX",((A9-B9)/B9*100))

and you might need to use a <= depending on how you want to treat -0.25% - C

4. Thanks. I knew someone out there had it. Will try and let you know how it works.
shortcut

5. Thanks again! Works like a charm!!!!!
shortcut