James has attended:
Excel VBA Intro Intermediate course
Access Intermediate course
Switch Clearing
When I select a salesperson or Manufacturer to run a form on, it is still possible to change the first drop down box and the salesperson or Manufacturer remains.
If I click "Go" at this stage, the wrong programme runs.
Is there any way to clear the second drop down box as soon as the value in the second is changed?
RE: Switch Clearing
Hi James
Thanks for your question
You need to create a change event for the first combo box. In that event you need one line of code
me.cmbreptype.value = ""
This will remove the entry, the entry in the selection combo, the instant you change the entry in the reptype combo.
The afterupdate method doesn't fire until you click on another control, and this is the reason it wasn't working from there
Regards
Stephen