Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 1
Default How do I use istext with a sum formula?

I have to add three cells together to get a total. The second cell could
possible have text in it. How do I use the istext formula?
  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 7,247
Default How do I use istext with a sum formula?

The SUM function ignores text values, so you could use

=SUM(A1:C1)
or
=SUM(A1,B1,C1)

Both formulas will ignore any non-numeric values. However, if a cell
has an error in it (e.g., #VALUE), SUM will return that error. To sum
a range that has error values, use

=SUM(IF(ISERROR(A2:C2),0,A2:C2))

Since this is an array formula, you *must* press CTRL SHIFT ENTER
rather than just ENTER when you first enter the formula and whenever
you edit it later. If you do this properly, Excel will display
the formula enclosed in curly braces { }. The formula will not
work properly if it is not entered as an array formula. For
much more information about array formulas, see
http://www.cpearson.com/Excel/ArrayFormulas.aspx.

Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)


On Mon, 8 Dec 2008 12:31:01 -0800, Jamie Thompson <Jamie
wrote:

I have to add three cells together to get a total. The second cell could
possible have text in it. How do I use the istext formula?

  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 3
Default How do I use istext with a sum formula?

I'm taking a class on Excel and I have to use the ISTEXT formula to get the
correct result. I have to add cells O27:029. Cell O28 uses nested if's to
come up with
a "shipping cost" depending on what state the items are being shipped to.
Two of the states say "No Cost". How would I use the ISTEXT formula with my
sum formula? My instructions say to "use help-look at istext". This is the
first time we are using this function so I don't have a clue how to put the
formula's together.
"Chip Pearson" wrote:

The SUM function ignores text values, so you could use

=SUM(A1:C1)
or
=SUM(A1,B1,C1)

Both formulas will ignore any non-numeric values. However, if a cell
has an error in it (e.g., #VALUE), SUM will return that error. To sum
a range that has error values, use

=SUM(IF(ISERROR(A2:C2),0,A2:C2))

Since this is an array formula, you *must* press CTRL SHIFT ENTER
rather than just ENTER when you first enter the formula and whenever
you edit it later. If you do this properly, Excel will display
the formula enclosed in curly braces { }. The formula will not
work properly if it is not entered as an array formula. For
much more information about array formulas, see
http://www.cpearson.com/Excel/ArrayFormulas.aspx.

Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)


On Mon, 8 Dec 2008 12:31:01 -0800, Jamie Thompson <Jamie
wrote:

I have to add three cells together to get a total. The second cell could
possible have text in it. How do I use the istext formula?


  #4   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 634
Default How do I use istext with a sum formula?

If you really have to use it then you could use something like:-

=SUM(O27,IF(ISTEXT(O28),0,O28),O29)

or perhaps

=IF(ISTEXT(O28),SUM(O27,O29),SUM(O27:O29)) - (Note the different
separators in the two SUMS)

but if you really want the brownie points in the class, you would be better
off understanding the difference between this solution and Chip's, give them
what they have asked for by using the examples above, and then use Chip's
solution to show why the ISTEXT function is really rather superfluous in
this example.

Regards
Ken................


"Jamie Thompson" wrote in message
...
I'm taking a class on Excel and I have to use the ISTEXT formula to get
the
correct result. I have to add cells O27:029. Cell O28 uses nested if's
to
come up with
a "shipping cost" depending on what state the items are being shipped to.
Two of the states say "No Cost". How would I use the ISTEXT formula with
my
sum formula? My instructions say to "use help-look at istext". This is
the
first time we are using this function so I don't have a clue how to put
the
formula's together.
"Chip Pearson" wrote:

The SUM function ignores text values, so you could use

=SUM(A1:C1)
or
=SUM(A1,B1,C1)

Both formulas will ignore any non-numeric values. However, if a cell
has an error in it (e.g., #VALUE), SUM will return that error. To sum
a range that has error values, use

=SUM(IF(ISERROR(A2:C2),0,A2:C2))

Since this is an array formula, you *must* press CTRL SHIFT ENTER
rather than just ENTER when you first enter the formula and whenever
you edit it later. If you do this properly, Excel will display
the formula enclosed in curly braces { }. The formula will not
work properly if it is not entered as an array formula. For
much more information about array formulas, see
http://www.cpearson.com/Excel/ArrayFormulas.aspx.

Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)


On Mon, 8 Dec 2008 12:31:01 -0800, Jamie Thompson <Jamie
wrote:

I have to add three cells together to get a total. The second cell
could
possible have text in it. How do I use the istext formula?




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
IF AND ISTEXT ISBLANK formula SCrowley Excel Worksheet Functions 5 October 6th 08 11:42 PM
IF(ISTEXT Concatenate formula question SCrowley Excel Worksheet Functions 15 October 9th 07 02:43 AM
IF-ISTEXT formula Cardian Excel Discussion (Misc queries) 6 August 6th 07 04:52 PM
ISTEXT TRUE then copy formula from cell X E Cobb Excel Worksheet Functions 7 May 31st 07 08:19 PM
I need help with a =sum IF ISTEXT formula. I keep getting 0. PullingMyHairOut Excel Discussion (Misc queries) 2 May 6th 05 01:31 PM


All times are GMT +1. The time now is 02:14 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"