+ Reply to Thread
Results 1 to 5 of 5

Data from tables to be brought on sheet

  1. #1
    Registered User
    Join Date
    11-03-2011
    Location
    Holt
    MS-Off Ver
    Excel 2010
    Posts
    27

    Data from tables to be brought on sheet

    Hello.
    I am having troubles (due to lack of programming skills) with following situation.

    My question is how to bring uniform from the "Loan" sheet into "Cadet search" sheet into the table which is marked as "Equipment on Loan"
    The data to be brought is dependent on Cadet's Surname + Cadet's ID

    Regards, Vlad
    Attached Files Attached Files

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Data from tables to be brought on sheet

    E12: =IF(COUNTIF(Loan!$B:$B,$C$11)>=ROW($A1),INDEX(Loan!C:C, MATCH($C$11, Loan!$B:$B, 0) +ROW($A1)-1), "")

    Now copy that formula down and across to column F. I presume prices will be coming from elsewhere?
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,485

    Re: Data from tables to be brought on sheet

    Here is your attached back.
    It is now a macro enabled workbook.
    Select a cadet, click the button the get the info.
    The assumption is that surnames may be the same but cadet numbers will only be assigned to one cadet.
    I added a price column just because you did not have one in your example.
    Play around with it,you will want to add a code to delete the info range.
    You can use your macro recorder for that.
    You can right click on one of your own buttons to assign the macro to it.

    Happy coding.
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    11-03-2011
    Location
    Holt
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Data from tables to be brought on sheet

    2 davesexcel
    Thanks, works great.
    One more question - how would I make it bring up Item and quantity?
    I was planning to have VLOOKUP to find the price from another table ( not included in my sample)

  5. #5
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,485

    Re: Data from tables to be brought on sheet

    Could you supply an example of the table you want to get your info from?

+ 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