I have Screen_1 and Screen_2.
Screen_1 has Form_1, Screen_2 has Gallery_1.
Gallery_1 has ComboBox_1, which has the following formula in items -
Gallery_1
and ComboBox_1
upon successful submission of Form_1
, you can follow these steps. Since the Reset
function does not seem to work within the OnSuccess
property of Form_1
, you can try resetting the Gallery_1
and ComboBox_1
by triggering the reset action through a variable.In Form_1
's OnSuccess
property, set a context variable that will be used to trigger the reset. Let's call this variable resetControls
.
UpdateContext({resetControls: true});
2. Modify the Reset_Btn
button to reset the context variable:
Add a button (you can hide it if you don't want it to be visible) to reset the resetControls
variable to false.
Reset_Btn.OnSelect: UpdateContext({resetControls: false});
3. Use the resetControls
variable to reset the Gallery_1
and ComboBox_1
:
In the properties of Gallery_1
and ComboBox_1
, use the Reset
function along with the resetControls
variable.
For ComboBox_1
:
ComboBox_1.Default: If(resetControls, Blank(), ComboBox_1.Default)
For Gallery_1
:
Gallery_1.Items: If(resetControls, [], Filter(colBillableUnits, !rem))
4. Trigger the reset button after form submission:
After updating the context variable to true
in the OnSuccess
property of Form_1
, trigger the reset button to reset the context variable to false
.
Form_1.OnSuccess: UpdateContext({resetControls: true}); Select(Reset_Btn)
This approach ensures that when Form_1
is successfully submitted, the resetControls
variable is set to true
, which triggers the reset logic in ComboBox_1
and Gallery_1
. The Reset_Btn
then sets resetControls
back to false
to reset the state.
By using this method, you should be able to clear the Gallery_1
and ComboBox_1
upon successful submission of Form_1
.
WarrenBelz
770
Most Valuable Professional
stampcoin
494
MS.Ragavendar
399