+ Reply to Thread
Results 1 to 4 of 4

Sum of a column of IF functions

  1. #1
    Registered User
    Join Date
    12-13-2013
    Location
    Michigan
    MS-Off Ver
    Excel 2010
    Posts
    78

    Sum of a column of IF functions

    Trying to auto calculate vacation time where it is earned at a rate of 9.538 hours/pay date.

    Column A has the pay dates (A1 has start date, A2 (=A1+14) and filled down to show all future pay dates. Works great

    Column B is to calculate additions to vacation time.
    (B2) =IF((A2) <= TODAY(), "9.538", "") and filled down

    This works great. If the date has past, 9.538 is entered into the coresponding B cell. If the date is in the future the coresponding B cell is blank.

    Now I want to in D1 calcualte the total of column B. =SUM(B2:B500) returns 0.00 When is should be 247.988 (I have tested with 2014 dates)

    If in D1 I put =SUM(B2+B3) it properly does the calcuation.

    I was thinking that the problem was that I was entering 9.538 as text and not a number but, if that is so why will it calculate (B2+B3)?
    Help!

  2. #2
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365, varying versions/builds
    Posts
    21,274

    Re: Sum of a column of IF functions

    The + operator will coerce numeric text to a true number, whereas SUM ignores all text. Your formula in B2 should be:

    =IF((A2) <= TODAY(), 9.538, "")
    Remember what the dormouse said
    Feed your head

  3. #3
    Registered User
    Join Date
    12-13-2013
    Location
    Michigan
    MS-Off Ver
    Excel 2010
    Posts
    78

    Re: Sum of a column of IF functions

    Perfect, Thank you

  4. #4
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365, varying versions/builds
    Posts
    21,274

    Re: Sum of a column of IF functions

    Glad to help.

    Please don't forget to mark the thread [Solved] using the 'Thread tools' link at the top of the page.

+ 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. Count items in column (column values generated by functions)
    By Sweetypie in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-14-2010, 09:32 AM
  2. Incrementing Functions by Column
    By thegrubixcube in forum Excel General
    Replies: 2
    Last Post: 02-12-2010, 11:28 AM
  3. How to use 'Column' name in VBA functions
    By guneetaulakh in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-23-2008, 09:22 AM
  4. [SOLVED] MIN/MAX functions and reporting from a different column
    By spodosaurus in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 10-02-2005, 01:05 PM
  5. how i can use functions for each value in a column by one proces.
    By ?/ in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-07-2005, 05:06 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