View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
danlinksman danlinksman is offline
external usenet poster
 
Posts: 14
Default whole number conditional formatting

I set it up just as you showed. If my formula resides in cell M2 and cell L2
= 1.83 and cell I2 = 2 and I divide L2/I2 I do not come out with a whole
number in cell M2. The formula you suggested turns the cell yellow, however
if cell L2 =2 and I2 = 2 I come out with a whole number of 1 and the cell
still remains yellow.

"Elkar" wrote:

That formula should work for what you're describing. Let's make sure you've
got it set up properly. Follow these steps:

Select cell M2
From the Format Menu, choose "Conditional Formatting"
Change "Cell Value Is" to "Formula Is"
Enter the formula: =MOD(M2,1)<0
Click the "Format" Button and select a yellow background
Click OK
Click OK

That should work.


"danlinksman" wrote:

It does not appear to be working correctly. IF cell M-2 has a formula of
L2/I2 and the results are not a whole number I want the cell to flag itself
with a color. If it comes our as a whole number the cell color stays normal.
When I tested your formula the conditional formatting continued did not work
properly. I was wanting the cell to turn "yellow" when, for instance, a
number came out 1.25 instead of 1.0. IF the cell result was 1.0 the cell
would look normal. Any more ideas?

"Elkar" wrote:

Use this formula in your Conditional Formatting:

=MOD(A1,1)<0

Where cell A1 is the cell where your formula is located.

HTH,
Elkar


"danlinksman" wrote:

I would like the cell to turn a highlight color if the result of a particular
formula is not a whole number.