Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 21
Default addding/omitting "x"

using this formula, =sumif(a10:a20,{"s1"},b10:b20)
I am trying to add all the values in b10:b20 excluding that is mark "x" in
colume C.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 35,218
Default addding/omitting "x"

First, you don't need the {}'s in your existing formula.

Second,
=sumproduct(--(a10:a20="s1"),--(c10:c20<"x"),b10:b20)

Adjust the ranges to match--but you can't use whole columns (except in xl2007+).

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

============

If you're using xl2007, there's a new =countifs() function that will do the same
kind of thing.

tleehh wrote:

using this formula, =sumif(a10:a20,{"s1"},b10:b20)
I am trying to add all the values in b10:b20 excluding that is mark "x" in
colume C.


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 20
Default addding/omitting "x"

Hi there.
1. Add all values in B10:B10 excluding those which have an X in the same row
column A:

=SUMIF(A10:A20,"<x",B10:B20)

2. Add all values in B10:B10 excluding those which have an X in the same row
column C:

=SUMIF(C10:C20,"<x",B10:B20)

b.t.w.: in my tests, I needed to format the criteria range (A10:A20 or
C10:C20) as text, select all the range and press DELETE before the formula
start working :(

Regards,
Otávio

"tleehh" wrote:

using this formula, =sumif(a10:a20,{"s1"},b10:b20)
I am trying to add all the values in b10:b20 excluding that is mark "x" in
colume C.

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
deleting or omitting "-"'s in a group of numbers w/ a formula Eric D Excel Discussion (Misc queries) 1 January 12th 09 07:58 PM
omitting/deleting "-"'s from numbers w/ formula Eric D Excel Discussion (Misc queries) 2 January 12th 09 07:27 PM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM


All times are GMT +1. The time now is 01:34 PM.

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

About Us

"It's about Microsoft Excel"