CONDITIONAL FORMATTING USING IF FORMULA

Copper Contributor

I am wanting to issue a conditional format for a cell to change from either positive or negative based on whether or not another cell is blank. I was able to come up with a formula that yielded the results i wanted however i would rather not have to add another column for the formula and just make it a condition that would automatically apply.  This is the formula i came up with and an example of what I am doing like i said ideally what is reflected in "d" would automatically condition in "c". On another note i am also trying to apply this condition not only in excel but to a google sheet as well.

 

=IF(ISBLANK(B4)=TRUE,C4*-1,C4*1)

ORDERPRO NUMBERTOTAL$ 
bobOUT$5,214.25 $      5,214.25
bob $5,614.40 $   (5,614.40)
bob $529.75 $       (529.75)
bob $32,000.00 $ (32,000.00)
bobOUT$193.64 $         193.64
bobOUT$3,956.15 $      3,956.15
bobOUT$620.50 $         620.50
bob   
bobOUT$247.50 $         247.50
bob $396.50 $       (396.50)
bobOUT$6,051.50 $      6,051.50
bobOUT$19,889.37 $   19,889.37
    $   36,172.91
3 Replies

Hello @LLOPEZ,

 

Try this formula:

=A1=""

 

Change A1 to your desired cell and Apply the formula to your desired range.

 

Hope this helps!

PReagan

@LLOPEZ 

Hi

If I understand properly, You need a conditional formatting in Column D (or maybe C) that popsup if the Value i is Negative: If so:

Select the cells in Column D (or C depending on where you want the formatting)

Click on the down arrow of Conditional Formatting >> Highlight Cell Rule >> Less than >> Type 0

Select the Format from the drop list (or custom format)

 

On the other hand, Your IF function can be more simple, as follows:

=IF(B4="",-C4,C4)

 

Hope that helps

Nabil Mourad

@LLOPEZ 

If that's about automatic conversion of numbers like $5,614.40 into ($5,614.40) if the cell to the left is empty - afraid that's only with VBA programming.