Remove/Clear the selected value from a combobox upon changing the value of another combobox

Steel Contributor

I have 2 combo boxes named; Street & Location. now I want to clear the selected value of the Location combo box when the Street combo box is changed? how I can do so? I do not want to reset the value i want to clear it. so it woks on Edit as well as on New forms

2 Replies

1. Select your Street combo box in the Power Apps studio.

2. Go to the "OnChange" property of the Street combo box and enter the following formula:


This formula will clear the selected value in the Location combo box when the Street combo box is changed.

3. If you want this to work for both new and edit forms, you can wrap the `Reset` function with an If statement that checks if the form is in edit mode.
For example:
If(EditForm.Mode = FormMode.New, Reset(Location))

This formula will clear the Location combo box only if the form is in the new mode. If it's in edit mode, the Location combo box won't be cleared.

4. Make sure you replace "EditForm" with the actual name of your edit form. You can do this by selecting your form and checking its properties.

Now, when you change the Street combo box in your form, it will clear the selected value in the Location combo box, but only in the new form. The edit form will not be affected.

@wfrf92 Reset() will not remove/clear the value it will reset it to the ThisItem value... this will not work specifically in Editform where there will be a value already..