SUM function to account for Text

AntBlabby8

Board Regular
Joined
Apr 18, 2002
Messages
192
I have a very wide spreadsheet, with many columns. In three columns--L, T, and AB--I have an IF formula that can render a sum of three columns to the left in each case, or the text "NO PRODUCT." In Col. AF, I then have a formula that says on Row 3, for example, =SUM(L3,T3,AB3). The problem I am having is if there is NO PRODUCT in either L, T, or AB, I am getting a VALUE! error. And because any or all of the three can have this NO PRODUCT in it, I don't know how to write a formula to get a total, and not a value error. HELP!
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).

Weaver

Well-known Member
Joined
Sep 10, 2008
Messages
5,196
What does your formula look like?

I'm surprised you're having this problem, since the sum function seems to ignore text.
 

VoG

Legend
Joined
Jun 19, 2002
Messages
63,650
Perhaps

=IF(COUNT(L3,T3,AB3)>0,SUM(L3,T3,AB3),"")
 

JoeMo

MrExcel MVP
Joined
May 26, 2009
Messages
17,890
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
I have a very wide spreadsheet, with many columns. In three columns--L, T, and AB--I have an IF formula that can render a sum of three columns to the left in each case, or the text "NO PRODUCT." In Col. AF, I then have a formula that says on Row 3, for example, =SUM(L3,T3,AB3). The problem I am having is if there is NO PRODUCT in either L, T, or AB, I am getting a VALUE! error. And because any or all of the three can have this NO PRODUCT in it, I don't know how to write a formula to get a total, and not a value error. HELP!
Excel's SUM function assigns a zero value to text, so the appearance of the text "NO PRODUCT" in any or all of the cells you are summing should not produce an error value. Check to see if one or more of the cells you are summing already contains a #VALUE!.
 

AntBlabby8

Board Regular
Joined
Apr 18, 2002
Messages
192
For some reason, the COUNT formula works. I am not sure why, but it does! I guess it is taking just the numbers as the text is not greater than zero theoretically? Anyhow, GREAT! I see what may be the issue. The column is formatted as ACCOUNTING. So it looks like TEXT but it isn't. That must be the problem. I see the words, but Excel sees the error. Hmmm. Anyhow, it's fabulously working now with that formua. Bravo, Mr Excel, to go-to place for us dangerous amateurs at Excel! THANKS AGAIN!
 
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,163,718
Messages
5,833,289
Members
430,202
Latest member
Faizal5zl

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top