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

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
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,833
Messages
6,121,862
Members
449,052
Latest member
Fuddy_Duddy

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