+ Reply to Thread
Results 1 to 3 of 3

Adding all cells across multiple sheets with certain formula.

  1. #1
    Registered User
    Join Date
    01-06-2016
    Location
    Oslo
    MS-Off Ver
    2010
    Posts
    15

    Adding all cells across multiple sheets with certain formula.

    Hi all.

    What I am trying to do is sum all cells across all sheets that contain a certain formuls.

    I am looking at the time difference used in my favor or their favor.. Here is an explination.

    I am using the E, F and G columns.

    E is the time I ordered something, F is the time it was delivered.

    G is the time difference showing either;
    In my favor: =(E(x)-F(x))
    In their favor: =(F(x)-E(x))

    I have roughly 45 sheets in this document, where all have used E,F and G the exact same way.

    How can I set up a formula on an "end sheet" to sum all sheets with =(E(x)-F(x)) and in another cell to sum all fields with =(F(x)-E(x)) ?

    That way I can see the totals for time in my vs time in their favor.

    It is in hours and minutes if that is important..

    Thank you in advance!

  2. #2
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481

    Re: Adding all cells across multiple sheets with certain formula.

    Hi there,

    Life (i.e. Excel life) always gets complicated when negative time values are involved

    Take a look at the attached workbook and see if it gets you moving in the right direction. A different approach could be used if your worksheet can accept helper columns, but I haven't tried that as I don't know your overall worksheet layout.

    The workbook uses the following code:

    Please Login or Register  to view this content.
    The highlighted values can be altered to suit your workbook/worksheet layout requirements.


    The problem was tricky but interesting!

    Hope this helps - please let me know how you get on.

    Regards,

    Greg M
    Attached Files Attached Files

  3. #3
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481

    Re: Adding all cells across multiple sheets with certain formula.

    Hi again,

    The attached workbook shows an alternative method which uses helper columns I and J, and less complicated VBA code - the helper columns may be hidden if required.

    The code involved is as follows:

    Please Login or Register  to view this content.
    The highlighted values can be altered to suit your own requirements.


    Hope this helps - please let me know how you get on.

    Regards,

    Greg M
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Adding cells in multiple sheets
    By memoe in forum Excel General
    Replies: 5
    Last Post: 09-03-2015, 09:59 PM
  2. Adding 1 to a range of cells on multiple sheets
    By dazbear in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-14-2014, 12:32 PM
  3. [SOLVED] Button for adding a new line across multiple sheets, inputting data to certain cells
    By jamief in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-06-2014, 08:40 PM
  4. Replies: 0
    Last Post: 02-06-2013, 09:10 PM
  5. Replies: 5
    Last Post: 01-20-2009, 11:56 AM
  6. adding cells from multiple sheets
    By macafeller in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-16-2007, 09:53 PM
  7. Adding Cells from Multiple Sheets
    By Kevin G in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-01-2005, 02:05 PM

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