09-25-2019 01:34 PM
09-25-2019 01:34 PM
I am trying to remove the blank selections from a dependent drop list I have created in Excel and I am having a hard time figuring out what the formula would be to get this accomplished. A little background, I have a table with two columns in the first column I have a drop down list feeding off of another sheet to get the manager names, formula is =Sheet1!$A$1:$EO$1. Then in second column I have a dependent drop down list that will populate specific portfolios based off the manager I had selected in the first column, formula is =INDEX(Sheet1!$A$2:$EO$67,,MATCH($A$5,Sheet1!$A$1:$EO$1,0)). The problem I am having is that most of the managers only have about 5 portfolios but one of those has about 65 portfolios, so when I select one of the smaller ones I have a bunch of blank spaces in my drop down list. Any help on how to get this resolved would be welcomed.
09-25-2019 08:46 PM
if the different managers have varying numbers of portfolios, then you need a distinct range for each manager that includes only the rows of data for that manager. In the attached spreadsheet you find three managers with three different range names. They have been created by selecting the manager name and the cells with text below it, then using Insert > Name > Create with the default to use the text in the top row for the range name. Any space in the range name will be replaced with an underscore.
The range name for portfolio uses the formula
It replaces the space in column A with an underscore and then uses that string to refer to the range name.
09-25-2019 11:18 PM - edited 09-25-2019 11:21 PM
Please check the attached file. you can find the explanation of the formula in below wep page, in the second tab. It is in Turkish however you can use web translator. (BAĞ_DEĞ_DOLU_SAY is COUNTA).
09-27-2019 01:44 PM
@H1D3F if anyone was curious, this is the formula I used in data validation to get all the blank spaces in my drop down list gone except for one. =OFFSET(Sheet1!$A$2:$EO$63,0,MATCH($A$5,Sheet1!$A$1:$EO$1,0)-1,COUNTA(OFFSET(Sheet1!$A$1,0,MATCH($A$5,Sheet1!$A$1:$EO$1,0)-1,65,1)),1)