+ Reply to Thread
Results 1 to 5 of 5

SUMIF function for multiple sheets

  1. #1
    Registered User
    Join Date
    06-10-2008
    Posts
    9

    SUMIF function for multiple sheets

    Can the SUMIF function be used for adding values that meet certain criteria over multiple sheets? I'm trying to create a formula that will search for a given name over 30-plus sheets and, if found, it will add the numbers given in another cell. I have had a similar problem just counting for names over multiple sheets, and was directed to use the Morefunc addin (=COUNTIF.3D), which worked perfectly. However, I was hoping it would also contain a function that would work the same way for SUMIF but I can't figure it out. Any help on this matter would be much appreciated. Thanks!

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    You can use the THREED() function from the Morefunc utility together with Sumproduct...

    e.g.

    =SUMPRODUCT((THREED(Sheet1:Sheet30!A1:A100)="X")*(THREED(Sheet1:Sheet30!B1:B100)))

    This would look through range A1:A100 in Sheets 1 to 30 for "X". It will sum values in B1:B100 where the "X" is found in A1:A100
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    06-10-2008
    Posts
    9
    it is returning a #REF! error. the formula i entered is:

    =SUMPRODUCT((THREED('Daytona 2-17:Homestead 11-16'!A3:A4)=B2)*(THREED('Daytona 2-17:Homestead 11-16'!F3:F4)))

    there are sheets later that have no values in them yet because the events have not taken place, would that be an issue?

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    I tried it using your sheetnames and it worked well for me....

    It shouldn't matter about the sheets with no values in them....

    Perhaps your actual sheetnames don't exactly match the sheetnames in the formulas? Check for extra spaces in the actual sheetnames.

  5. #5
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264
    This is probably a moot point because you already have morefunc installed, but you can do it without morefunc. Assume you have your sheets you want to sum listed in a range somewhere (eg Z1:Z30 of the sheet the formula is on) then:

    =SUMPRODUCT(SUMIF(INDIRECT("'" & Z1:Z30 & "'!A3:A4"),B2,INDIRECT("'" & Z1:Z30 & "'!F3:F4")))

    Richard

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1