How to reset a text field based on a drop down selection
Is there a way to reset (clear entered data) when a drop down selection is changed? I have a form that has different form fields display based on the drop down selection.
For example:
If Drop down selection= "dd1"
Then Text boxes "Text 1" and "Text 2" are visable and "Text 3" and "Text 4" are hidden
If Drop down selection= "dd2"
Then Text boxes "Text 3" and "Text 4" are visable and "Text 1" and "Text 2" are hidden
The values of "Text 1" and "Text 2" OR "Text 3" and "Text 4" need to populate in two text fields at the end of the form. The problem that I am having is that if someone first selects "dd1" and fills out "Text 1" and "Text 2" and then changes their mind and changes their selection to "dd2", and enters new values for the now corresponding "Text 3" and "Text 4", the populated value for the two text fields at the end of the form still show the values for "Text 1" and "Text 2" because the text fields are hidden when the new selection is made, but not cleared. Any help would be appreciated!
