Forum Discussion

M2021L's avatar
M2021L
Copper Contributor
Nov 15, 2021
Solved

Autopopulate a drop down from another drop down

How do I set up to autofill several cells (containing drop downs) depending on the value of another drop down?

 

For example,

If x is selected from the dropdown in column A, then I want Columns B-F to say 'N/A', but if Y is selected, I want columns B-F as drop downs

 

Thank you

12 Replies

    • bsiemens's avatar
      bsiemens
      Copper Contributor

      This is exactly what I'm trying to do but I'm having difficulty with the formula. I'm not sure how to use IF, VLOOKUP, etc. 

      • Please download the sample workbook from my first reply.

        Right-click the sheet tab of the first sheet and select View Code from the context menu to see the VBA code used.

    • M2021L's avatar
      M2021L
      Copper Contributor

      HansVogelaar This is exactly what I wanted! Thank you so much. 

       

      How do go about setting it up on a different workbook?

      • M2021L 

        You'll need to copy the code from the worksheet module *) to the worksheet module of the sheet you want to apply it to, and modify the code according to the exact setup you have.

         

        *) Right-click the sheet tab and select View Code from the context menu to activate the Visual Basic Editor and view the worksheet module.

         

        I used named ranges for the data validation rules. See Formulas > Name Manager.

Resources