+ Reply to Thread
Results 1 to 10 of 10

Count values from cells depending on drop down selection

  1. #1
    Registered User
    Join Date
    05-07-2014
    Location
    Costa Rica
    MS-Off Ver
    Excel 2010
    Posts
    5

    Count values from cells depending on drop down selection

    Hello Guys,

    I have a sheet (sheet A) with a drop down that populates a report feeding from another sheet (sheet b) using data validation. On sheet A I keep track of the amount hours I spent daily on a project. but I need help finding a way for Sheet B to keep a track of the total amount of hours spent on every project monthy based on how many hours are used on Sheet A. (Please consider the projects on Sheet A are never populated in order.)
    I've attached a couple of screenshots to help explain what I'm looking for.
    Attached Images Attached Images
    Last edited by metch; 02-12-2016 at 03:27 PM.

  2. #2
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    Pictures are nice but one cannot work with them. Please attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

  3. #3
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    Pictures are nice but one cannot work with them. Please attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic

  4. #4
    Registered User
    Join Date
    05-07-2014
    Location
    Costa Rica
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Count values from cells depending on drop down selection

    Hello Guys,

    I'm sorry for the delay on this post, I'd been busy with a huge project and totally forgot about this.
    I'm attaching two Spreadsheets which work together: "Weekly Billable Timesheet.xlsm". and "Contract List.xls" the Timesheet spreadsheet grabs the Company Name Values from the Contract list spreadsheet. In order to work they both need to be open and reside on the same folder.
    Please note "Weekly timesheet" is macro Enabled.


    Basically What Im looking to accomplish here is for Contract list under the column HRS spent to automatically count the ammount of hours that every project has spend so far. Counting the hours from the Weekly Timesheet on a project basis.
    In other word every time I add lets say "Bank of Venus" on the "Weekly Timesheet" spreadsheet and add hours to it, those hours should increase the number of total hours spent on the HRS spent column of the "Contract list" Spreadsheet.

    I hope that explains what Im looking for. Let me know if you need further clarification. or if you have troubles making the two spreadsheets work together
    Attached Files Attached Files

  5. #5
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    If I understand what you are after, enter this in Contracts list .xlsx L3 and fill down: (both files have to be open for the calculation)
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    05-07-2014
    Location
    Costa Rica
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Count values from cells depending on drop down selection

    Thank you Very much newdoverman. That's exactly what I needed! now Im expanding the formula so it uses multiple sheets:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    I don't want to have to modify the formula everytime I add a new weekly time sheet . I tried using "ISERROR" to ignore whether the sheet exists or not but I guess I don't how to use it or it doesn't work with SUMIFS.

    Thanks in advance.

  7. #7
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    If it was my project, I wouldn't use a worksheet for each week nor would I use a separate workbook for the data and the report. I would have all the data and report in one workbook with the data in a table. I have done this using your supplied data and converting the 3 weeks into a single table and then using that table to extract the data required using this formula (table is on Sheet1)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    This will make more sense if you look at the workbook. As you add data, the table will extend and the formulae will automatically expand to accommodate the new data.

    Using the table, you can easily produce a Pivot Table to create various reports and you can easily isolate each contract to see the data only for that contract or selected contracts...the possibilities are many without having to do a great deal of work to produce.
    Attached Files Attached Files
    Last edited by newdoverman; 09-05-2016 at 02:46 PM.

  8. #8
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    First: Sumif could have been used instead of Sumifs. The terms would just have to be re-arranged to match the requirements of SUMIF.

    Here is a formula that will work to sum new worksheets in the separate workbook IF you create a list of the worksheet tabs in the Contracts list-1.xlsx workbook and give it a name. I named the list which I have in a table named Tabs.

    Capture.JPG

    The formula in K3 of Contracts list-1.xlsx would be like this:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    When you add a worksheet to the Weekly Billable....workbook, add the worksheet to the Contracts List workbook with this syntax
    [Weekly Billable Time Sheet 2016 - Copy-1.xlsm]Week #34

    Here are your workbooks with the formula summing across the range of worksheets.
    I think that this is much more difficult to maintain but that is up to you.
    Last edited by newdoverman; 09-05-2016 at 09:10 PM. Reason: Wrong files uploaded

  9. #9
    Registered User
    Join Date
    05-07-2014
    Location
    Costa Rica
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Count values from cells depending on drop down selection

    Thank you New Doverman,

    I actually started with a single book in a similar way as that one is, however it was not very effective for me for numerous reasons. That's how I ended with a separate workbook.
    I tried using sumproduct but It didn't worked, now I see what my error was. I was not creating a list of tabs inside contracts list.xlsx. It now works like a charm!

    Again as always I really appreciate your time and effort!
    Last edited by metch; 09-10-2016 at 03:09 PM.

  10. #10
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Count values from cells depending on drop down selection

    Thank you for the feedback.

    If you follow the last upload that I gave you, you will notice that the tabs are listed in a table. This table will expand the defined name for the range so that you don't have to continually change the definition of the name.

    Good luck.

+ 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. Replies: 20
    Last Post: 10-16-2015, 09:56 AM
  2. Applying Certain Formulas depending on Drop Down Selection
    By Mountaineer86 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-06-2013, 05:30 PM
  3. Replies: 5
    Last Post: 06-21-2013, 08:42 AM
  4. Make a box appear / disappear depending on drop down form selection
    By excelyee in forum Excel Programming / VBA / Macros
    Replies: 24
    Last Post: 02-27-2013, 01:29 PM
  5. Make a box appear / disappear depending on drop down form selection?
    By simonwilliams in forum Word Formatting & General
    Replies: 0
    Last Post: 03-09-2011, 10:21 AM
  6. Changing cell values depending on drop down selection
    By a022227 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 11-14-2008, 10:35 AM
  7. Auto fill cells depending on Drop down List selection
    By Trengor in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 09-22-2008, 11:06 AM

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