I have this simple radio button with items Yes, No.
I have below formula at OnSelect of the Submit button.
Patch(Binaries,Defaults(Binaries),{Title:Radio1.Selected.Value});UpdateContext({varResetRadio: true})
I have placed my context variable varResetRadio at Reset property of the radio button.
Now I have placed a label on the screen to check the current value selected in radio options. I have put Radio1.Selected.Value at text property of the label.
Now when I click on submit, neither the label value becomes blank nor the radio button resets. But when I take another button to reset the radio control with Reset(radio1), it resets perfectly. Am I doing something wrong in this simple action? Or is this a bug when I use a variable at Reset property of radio button?
Thanks in advance,
Ramesh Mukka
Solved! Go to Solution.
Hi,
When using the reset property, the value needs to be set to false manually, then to true, then to false again. I would recommend just to use the reset function instead as you have done, and replace your UpdateContext with reset instead:
Patch(
Binaries,Defaults(Binaries),
{Title:Radio1.Selected.Value});
Reset(Radio1)
@iAm_ManCat |
Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you! |
Thanks! |
Hi,
When using the reset property, the value needs to be set to false manually, then to true, then to false again. I would recommend just to use the reset function instead as you have done, and replace your UpdateContext with reset instead:
Patch(
Binaries,Defaults(Binaries),
{Title:Radio1.Selected.Value});
Reset(Radio1)
@iAm_ManCat |
Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you! |
Thanks! |
@iAm_ManCat Thank you for taking some time. My actual problem was on my app where am building with close to 100 input controls. So idea was to reset them at Form Submit so I was using this Reset property with variable instead using Reset() function for all those 100+ controls. How would you want me to do in this case?
Are all of your controls in the form? If Yes, then use
ResetForm(FormName); NewForm(Formname)
@iAm_ManCat |
Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you! |
Thanks! |
No, I am not using a form control. So I went for Reset property using variable as that was easy. And used below formula as you suggested. It worked. Thanks a lot.
Set(
varResetCtrls,
false
);
Set(
varResetCtrls,
true
);
Set(
varResetCtrls,
false
);
User | Count |
---|---|
162 | |
91 | |
68 | |
64 | |
63 |
User | Count |
---|---|
210 | |
157 | |
93 | |
81 | |
71 |