+ Reply to Thread
Results 1 to 5 of 5

Get set of multiple values from a table based on condition

  1. #1
    Registered User
    Join Date
    08-25-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    10

    Get set of multiple values from a table based on condition

    Hi,

    I have a table with 3 columns for each date - "Actual", "Plan" and "Hrs".

    My need is to show in a single cell, all the dates and corresponding value in "Actual" column wherever Actual value is > 0.

    The sample data and need is illustrated in the attachment

    Please note that in sample, there are only few dates shown. The actual data will have 31 dates for the month

    Thanks,
    Vivek
    Attached Files Attached Files

  2. #2
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Get set of multiple values from a table based on condition

    Add the below code in a module of that workbook.

    How to install your new code
    1. Copy the Excel VBA code
    2. Select the workbook in which you want to store the Excel VBA code
    3. Press Alt+F11 to open the Visual Basic Editor
    4. Choose Insert > Module
    5. Edit > Paste the macro into the module that appeared
    6. Close the VBEditor
    7. Save your workbook (Excel 2007+ select a macro-enabled file format, like *.xlsm)

    Please Login or Register  to view this content.
    In D10 Cell

    =ClookupExt(C10,$B$4:$P$4,$B$3:$P$3,$B$5:$P$5)

    Drag it down…


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  3. #3
    Registered User
    Join Date
    11-21-2012
    Location
    Al Ain, UAE
    MS-Off Ver
    Excel 2003
    Posts
    16

    Re: Get set of multiple values from a table based on condition

    Please check the attached file.
    Run the macro.
    Modify it as per your need.

    Thanks and Regards,
    Mohammad Sherif
    Attached Files Attached Files

  4. #4
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,595

    Re: Get set of multiple values from a table based on condition

    Pl see the attached file with UDF "GetData".
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    08-25-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    10

    Re: Get set of multiple values from a table based on condition

    Hi SixthSense,

    This worked perfectly
    Thanks !

  6. #6
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Get set of multiple values from a table based on condition

    Based on your last post in this thread, its apparent that you are satisfied with the solution(s) you've received and have solved your question, but you haven't marked your thread as "SOLVED". I will do it for you this time.

    In future, to mark your thread as Solved, you can do the following -
    Select Thread Tools-> Mark thread as Solved.

    Incase your issue is not solved, you can undo it as follows -
    Select Thread Tools-> Mark thread as Unsolved.

    Also, since you are relatively new to the forum, i would like to inform you that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post which helped you. This adds to the reputation of the person who has taken the time to help you.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ 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. Pick up values from a table based on 1 condition
    By batchjb69 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 08-10-2013, 04:44 AM
  2. Pivot Table based on specific values from multiple columns
    By Jaypoc in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 06-22-2013, 12:33 PM
  3. [SOLVED] Extracting multiple values based on the condition...Pls help (Urgnt)
    By krratheesh80 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-21-2012, 10:06 AM
  4. Insert multiple values from seperate table based on multiple conditions
    By drakesong in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 02-28-2011, 06:04 PM
  5. Sum values from multiple worksheets based on a condition
    By ledisnomad in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 02-15-2010, 11:26 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