+ Reply to Thread
Results 1 to 10 of 10

Excel 2007 : Averaging no blanks and no zeros over several Sheets

  1. #1
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    Averaging no blanks and no zeros over several Sheets

    Hello I am looking for some help with averaging cells over 20 plus sheets. I do not want blanks or zeros counted. This is what I have used with a few variants but I do not get anywhere with it.

    =SUM('WK1 Mon'!D13:'WK1 Tue'!D13:'WK1 Wed'!D13:'WK1 Thu'!D13:'WK1 Fri'!D13:'WK2 Mon'!D13:'WK2 Tue'!D13:'WK2 Wed'!D13:'WK2 Thu'!D13:'WK2 Fri'!D13:'WK3 Mon'!D13:'WK3 Tue'!D13:'WK3 Wed'!D13:'WK3 Thu'!D13:'WK3 Fri'!D13:'WK4 Mon'!D13:'WK4 Tue'!D13:'WK4 Wed'!D13:'WK4 Thu'!D13:'WK4 Fri'!D13:'WK5 Mon '!D13:'WK5 Tue'!D13:'WK5 Wed'!D13:'WK5 Thu'!D13:' WK5 Fri'!D13)/sumproduct/(countif(indirect(""&'WK1 Mon'!D13:'WK1 Tue'!D13:'WK1 Wed'!D13:'WK1 Thu'!D13:'WK1 Fri'!D13:'WK2 Mon'!D13:'WK2 Tue'!D13:'WK2 Wed'!D13:'WK2 Thu'!D13:'WK2 Fri'!D13:'WK3 Mon'!D13:'WK3 Tue'!D13:'WK3 Wed'!D13:'WK3 Thu'!D13:'WK3 Fri'!D13:'WK4 Mon'!D13:'WK4 Tue'!D13:'WK4 Wed'!D13:'WK4 Thu'!D13:'WK4 Fri'!D13:'WK5 Mon '!D13:'WK5 Tue'!D13:'WK5 Wed'!D13:'WK5 Thu'!D13:' WK5 Fri'!F:N,"<>0")

    I have also used =sum(sheet cell)/countif(sheet cells, "<>"0)

    any ideas please
    Last edited by NBVC; 07-05-2010 at 03:19 PM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Averaging no blanks and no zeros over several Sheets

    Try this:

    List all the names of the sheets in a single column in your summary sheet. Then select that range of sheetnames and go to Insert|Name|Define and call that range: TabNames

    Then use this formula:

    Please Login or Register  to view this content.
    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
    02-20-2008
    Posts
    22

    Re: Averaging no blanks and no zeros over several Sheets

    Quote Originally Posted by NBVC View Post
    Try this:

    List all the names of the sheets in a single column in your summary sheet. Then select that range of sheetnames and go to Insert|Name|Define and call that range: TabNames

    Then use this formula:

    Please Login or Register  to view this content.
    This is what I enterentered and now I get the following #REF!

    =SUMPRODUCT(SUMIF(INDIRECT("'"&'Summary '!AA1:AA25&"'!D13"),">0",INDIRECT("'"&'Summary '!AA1:AA25&"'!D13")))/SUMPRODUCT(COUNTIF(INDIRECT("'"&'Summary '!AA1:AA25&"'!D13"),">0"))

    Also I should have mention that the Tab names change monthly, but for now that can wait

    Thanks
    Last edited by kithing; 07-05-2010 at 12:59 PM.

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Averaging no blanks and no zeros over several Sheets

    Are you sure that 'Summary '!AA1:AA25 contains the exact names matching the sheetnames? And that they all exist?

  5. #5
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    Re: Averaging no blanks and no zeros over several Sheets

    I did not understand that I needed to create a table. I did that on the summary tab. I inserted your Formula exactly as you entered it. My table name is TabNames but now I get the following #NAME?

  6. #6
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    Re: Averaging no blanks and no zeros over several Sheets

    The names of the tabs are correct in the table as thet are on the Tabs

  7. #7
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Averaging no blanks and no zeros over several Sheets

    You could do it by referencing the range as you had attempted.. it is just easier to manage as a named range.

    If you are getting that error, something is typed incorrectly or you did not actually create the name correctly.

    Can you post your new formula. ... also go to Insert|Name|Define and check that you have indeed a TabNames name in the list.

    If you can post a sample workbook, that would be best way to resolve this.

  8. #8
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    Re: Averaging no blanks and no zeros over several Sheets

    Quote Originally Posted by NBVC View Post
    You could do it by referencing the range as you had attempted.. it is just easier to manage as a named range.

    If you are getting that error, something is typed incorrectly or you did not actually create the name correctly.

    Can you post your new formula. ... also go to Insert|Name|Define and check that you have indeed a TabNames name in the list.

    If you can post a sample workbook, that would be best way to resolve this.
    I have up loaded the file tahnks for you help
    Attached Files Attached Files

  9. #9
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Averaging no blanks and no zeros over several Sheets

    See attached.

    First, you did not have a named range called TabNames created... now I created one. I also made it dynamic, so that you can add to the bottom of the list in column S if you add new sheets.

    Also, 2 of the sheetnames were not exactly correct.

    The WK5 Mon tab had a trailing space and the WK5 Fri had a space at the front.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    [SOLVED] Re: Averaging no blanks and no zeros over several Sheets

    Thank you very Much

+ 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