+ Reply to Thread
Results 1 to 5 of 5

Subtotal, Sumif Only Showing Visible

  1. #1
    Registered User
    Join Date
    10-28-2005
    Posts
    6

    Subtotal, Sumif Only Showing Visible

    I have read through the posts on with subtotal and sumif in the forums, but can't get this one working.

    I have a workbook that is pulling in data from MSSQL 2005. I am trying to show a total at the end of a column based on if a second column contains a certain value. I can do this with sumif, but when I run filters it doesn't change the totals.

    So for instance

    G H J
    $10.00 DAP 01/01/2005
    $10.00 DAP 01/01/2005
    $10.00 DAP 02/01/2005
    $10.00 JBB 02/01/2005


    If I want the total for column 1 where all column H = DAP then I use this:

    =SUMIF(H2:H3058,"DAP",G2:G3058)

    and I get a total of $30.00, but when I filter add a filter and only pull dates from Jan 01/2005, then it still shows $30.00. I am trying to get it so that when I apply the filter it shows $20.00.

    Any help would be greatly appreciated.

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

    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
    10-28-2005
    Posts
    6
    Holy crap.... That worked... Thank you. Now I am just trying to figure out what it says. :D

  4. #4
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    dprichard,

    Please read forum rules below and message to cross posters and then add the cross post to the other forum.

    VBA Noob
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  5. #5
    Registered User
    Join Date
    10-28-2005
    Posts
    6
    Sorry VBA Noob. I didn't realize I was doing anything wrong. I have been posting in multiple forums for 8-9 years now and you are the first person to ever point out that posting on different sites is cross posting. I thought that had to do with posting in multiple forums on the same site. There are just so many people out there that are so stuck on themselves and think they are too smart to give real answers and only give sarcastic put downs to people in forums, or people that think they know all the answers and give wrong ones that I find it easier to get a good answer by posting in multiple places. I will remember your advice on posting going forward.



    Thanks for the answers NBVC. Your solution worked perfectly.

+ 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