+ Reply to Thread
Results 1 to 9 of 9

Create dynamic list by looking up matrix

  1. #1
    Registered User
    Join Date
    04-23-2017
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    4

    Create dynamic list by looking up matrix

    Hoping to get some advice on the below problem.

    Trying to create a dynamic list from a matrix.

    I have created a matrix in one worksheet that cross references the tool/equipment with the Job Type. Tools are listed in column A and then the job type in row A5:K5. If the tool is required for a job type, the corresponding cell will have the number "1". If the cell is blank, the tool is not required (worksheet = 'Stock and Equipment Matrix').

    On a separate worksheet (known as 'Job Sheet 1'), I want excel to auto populate the list of tools required dependent on the Job Type identified in Cell A13. The list should be populated from cell A17 downwards and not leave any blank rows.

    I've been playing around with a variety of formula and can't quite get it to work the way I want.

    (also worth noting that the 'Job Sheet 1' cell A13 will auto populate based on other worksheets that are also linked to the list of job types).

    Look forward to some feedback
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,193

    Re: Create dynamic list by looking up matrix

    In A17

    =IFERROR(INDEX('Stock & Equipment Matrix'!$A$6:$A$31,SMALL(IF(INDEX('Stock & Equipment Matrix'!$B$6:$K$31,0,MATCH('Job Sheet 1'!$A$13,'Stock & Equipment Matrix'!$B$5:$K$5,0))=1,ROW('Stock & Equipment Matrix'!$A$6:$A$31)-ROW($A$6)+1,""),ROWS($A$6:A6))),"")

    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.

    I added a named range "Equipment" (see Column L in 'Stock and Equipment Matrix') to be used in Data Validation in "Pricing Guide".
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    04-23-2017
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    4

    Re: Create dynamic list by looking up matrix

    Quote Originally Posted by JohnTopley View Post
    In A17

    =IFERROR(INDEX('Stock & Equipment Matrix'!$A$6:$A$31,SMALL(IF(INDEX('Stock & Equipment Matrix'!$B$6:$K$31,0,MATCH('Job Sheet 1'!$A$13,'Stock & Equipment Matrix'!$B$5:$K$5,0))=1,ROW('Stock & Equipment Matrix'!$A$6:$A$31)-ROW($A$6)+1,""),ROWS($A$6:A6))),"")

    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.

    I added a named range "Equipment" (see Column L in 'Stock and Equipment Matrix') to be used in Data Validation in "Pricing Guide".


    Thank you for this assistance - greatly appreciated.

    However there appears to be an error in the formula (the same one I had trouble with).

    Working with your example, I have cross referenced the results the formula generates. There is one weird issue with only one tool - the first on the list "PG450".

    This tool does not show for the below job types even though it has a 1 in the stock and equipment matrix
    - Grind & Seal
    - Polished Concrete
    - Glue Removal
    - RHINO Glue Removal
    - Repair & Re-Seal

    AND then - it shows for the Job type 'Spray Paving' when it's not meant to?

    I'm not sure if the formula is off or not?

    Thanks so much for your help thus far

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Create dynamic list by looking up matrix

    Hi Lana,

    See the attached where I've done fancy things. I took your table and made a better table out of it (using Power Query UnPivot) but you don't need to do that again.

    I used this "better table" and created an Advanced filter macro on Sheet1 to the tools needed. I then took your A13 and did an Event Macro on it, so when you changed it the fancy stuff happens. It copies A13 to the criteria of the advanced filter and then does the new Advanced Filter macro. The results below A13 are simply what the filter shows on sheet1.

    Jobs and Tools PQ Unpivot On Change Adv Filter.xlsm
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  5. #5
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,193

    Re: Create dynamic list by looking up matrix

    It does not show because it is not entered with CSE (error in my posting).

  6. #6
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,193

    Re: Create dynamic list by looking up matrix

    It does not show because not CSE entered
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    04-23-2017
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    4

    Re: Create dynamic list by looking up matrix

    Perfect!! thanks so much - you are brilliant

  8. #8
    Registered User
    Join Date
    04-23-2017
    Location
    Melbourne, Australia
    MS-Off Ver
    MS Office 365
    Posts
    4

    Re: Create dynamic list by looking up matrix

    thank you!

  9. #9
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,193

    Re: Create dynamic list by looking up matrix

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. Create dynamic drop down list from dynamic data source
    By rz6657 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-18-2016, 05:22 PM
  2. [SOLVED] How do i create a list on a sheet, based on an entry in a matrix
    By cumiskeya in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-14-2016, 10:41 AM
  3. Create a dynamic list based on multiple dynamic factors.
    By sabin348 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 08-07-2015, 11:05 AM
  4. [SOLVED] Populating a Matrix using a dynamic list
    By dcossyl in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 06-19-2015, 01:06 PM
  5. create dynamic drop down list for large list of data
    By Dariusd7 in forum Excel General
    Replies: 2
    Last Post: 05-10-2014, 04:39 AM
  6. Create a dependent drop down list with dynamic list
    By JSmith1504 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-01-2014, 09:15 AM
  7. Replies: 0
    Last Post: 10-02-2012, 09:09 AM

Tags for this Thread

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