Default Drop-Down Based on Cell Value

Frequent Visitor

Good evening.


I'm wondering if there's a way to auto-populate an item in a drop-down menu based on the value entered in a different cell.


What I'm trying to accomplish: Cell E7 is a drop-down containing only the selection "QA Due". When this value is entered in E7, I'd like M7 to auto-populate the word "Pending", but ALSO contain a drop-down box which can be changed to "Complete". When M7 is changed to "Complete", S7 then auto-populates the word "No", but is also a drop-down that can be changed to say "Yes".


I have figured out one way to do this by applying Data Validation List to cells M7 and S7 with their available options ("Pending" or "Complete", and "Yes" or "No", respectively), then turning off the error alert and applying an IF formula. For example, to M7 I would apply this formula: =IF(E7="QA Due","Pending","") after which I re-apply the error alert.


This works, but leaves the formulas exposed, meaning if the user accidentally clicks the cell and hits "delete" the formula no longer exists to auto-populate the response in M7 when "QA Due" is selected in E7. Or, if the user selects a drop-down item from M7 before selecting the drop-down item in E7, the formula no longer exists. If I protect the cell and worksheet, the drop-down no longer works.


Is there any way for this to work?


For the record, I have never used VBA or macros so I'm hoping to avoid those if at all possible.


QA Tracker Snapshot.jpg



1 Reply


It looks like you have figured out the strengths and weaknesses of data validation dropdowns.


If you add an empty string "" to your data validation source, you won't need to turn error alert off when you apply the formula.


If you need to reapply the formula after the user has deleted it by making a data validation dropdown choice, then VBA is the way to go. I suggest adding a button to the worksheet to call the re-initialization macro. VBA is also the way to go if you want to prevent the user from making a selection in M7 or S7 until after they have made a selection in the preceding dropdown. This could be done by a Worksheet_Change event macro.


I realize that you don't know how to write the required VBA code, but it is pretty easy. If you post your workbook, I'd be glad to show you how it's done.