![]() |
Count
Is there a way of adding blank cells and without getting a result of 0
E.g. =sum(A1+B2) Answer is 0 is there a way of just have a blank cell Cells A1 and B2 are blank ---------------------------------------- All this to make conditional formatting to work:- Blank cell = no colour 0 = Green 1 = Yellow Between 2 and 999 = Red Hope you can help Regards |
Count
Try this:
=IF(AND(A1="",B1=""),"",A1+B1) Hope this helps. Pete On Jan 26, 10:36*am, "Stig - tame racing driver" <Derek- wrote: Is there a way of adding blank cells and without getting a result of 0 E.g. =sum(A1+B2) * *Answer is 0 is there a way of just have a blank cell Cells A1 and B2 are blank ---------------------------------------- All this to make conditional formatting to work:- Blank cell = no colour 0 = Green 1 = Yellow Between 2 and 999 = Red Hope you can help Regards |
Count
For a start, you don't need the SUM function if you are not asking it to sum
two or more arguments. You can use either SUM(A1,B2) or just =A1+B2. To deal with blank inputs, you could use =IF(COUNT(A1,B2)=2,A1+B2,"") if you want both inputs to be non-blank, or =IF(COUNT(A1,B2)=0,"",A1+B2) if you want either to be non-blank. -- David Biddulph "Stig - tame racing driver" wrote in message ... Is there a way of adding blank cells and without getting a result of 0 E.g. =sum(A1+B2) Answer is 0 is there a way of just have a blank cell Cells A1 and B2 are blank ---------------------------------------- All this to make conditional formatting to work:- Blank cell = no colour 0 = Green 1 = Yellow Between 2 and 999 = Red Hope you can help Regards |
Count
Thanks again.... problem solved
"Pete_UK" wrote in message ... Try this: =IF(AND(A1="",B1=""),"",A1+B1) Hope this helps. Pete On Jan 26, 10:36 am, "Stig - tame racing driver" <Derek- wrote: Is there a way of adding blank cells and without getting a result of 0 E.g. =sum(A1+B2) Answer is 0 is there a way of just have a blank cell Cells A1 and B2 are blank ---------------------------------------- All this to make conditional formatting to work:- Blank cell = no colour 0 = Green 1 = Yellow Between 2 and 999 = Red Hope you can help Regards |
Count
You're welcome, Stig.
Keep racing. Pete On Jan 26, 11:09*am, "Stig - tame racing driver" <Derek- wrote: Thanks again.... problem solved |
All times are GMT +1. The time now is 07:10 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com