im interested to implement something but im not sure if it would be possible and would like your intake on it.
here is my scenario:
i will have two validation cells which will be shown as List that I will pick from.
those are my condition that i would like to meet and ommit my list from a database.
I have a list of agents going threw B13:B23 and next two them i have columns of data
assuming that my data base looks like this
B C D E
X | Y | Z
agent1 1 | 1 | 0
agent2 0 | 1 | 0
agent3 0 | 1 | 1
agent4 1 | 0 | 0
…
i want to populate a list of agent name from column B, when i select from the validation cell1: X and validation cell2: 1.
it should show only
column:
agent1
agent4
or agents in column X with 0…
i read somewhere about array formula but i dont know if this is convenient and i unfortunately dont have any background in macros:( but i know in C++ something like this is fairly easy with conditional statements.
thanks in advance,
It is possible. One way to approach this is to call a sub that lists you the relevant agents whenever the Target in your Worksheet_Change intersects with validation cell1 or cell2 -> the validation changed.
Then you would run a sub with 3 paramenters srcRange, validationColumn and validationValue that goes throgh each row of srcRange and checks if the cell on position rownumber, validationColumn is equal to validationValue if so it outputs the agent and sets outputrow + 1
Put this VBA in your Sheet:
I tested it on your example and it worked.