IsNumber?

karlruff

Board Regular
Joined
Sep 24, 2003
Messages
91
Hello,
Could anyone recommend a formula for checking if the contents of each of the cells in a range contains a number, and if so, return the sum of those numbers?
Thanks
b
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
I should have been more clear. If the formula finds the contents of any cell in the range is NOT a number, I need the formula to return an "N/A".
Thx
b
 
Upvote 0
Does this work for you (as an array)

=(ISTEXT(Range)=FALSE)*(SUM(Range))

Commit using SHIFT + CTRL + ENTER

Should see {=(ISTEXT....)}

Change range refs to A1:A10 or whatever range you need - would return 0 rather than error.

----------------------------

EDIT:

SORRY... this will work for you but will return DIV/0 as error rather than 0

=SUM(Range)/(ISTEXT(Range)=FALSE)

Again, commit as array
 
Last edited:
Upvote 0
Are you not wanting to sum if any of them are blank or if any of them contain text?

If text, perhaps:

=IF(COUNTIF(A1:A10,"?*"),"N/A",SUM(A1:A10))

or if either, perhaps:

=IF(COUNT(A1:A10)=ROWS(A1:A10),SUM(A1:A10),"N/A")
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,947
Messages
6,122,411
Members
449,081
Latest member
JAMES KECULAH

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
Back
Top