I searched around but couldn't find the right answer to my question. I'm trying to save a form that relies on a Toggle to change the DisplayMode, so that several fields are disabled when it's off. Some of those fields have Required set to true in Power Apps (but not in the SharePoint list the form is connected with).
I can save the form when those fields are toggled on and in edit mode, but not when they're disabled. I'd like to keep those fields as required when the form is in Edit mode, but not required when they're disabled by the toggle.
Form OnVisible:
UpdateContext({ChangeDisplayMode: DisplayMode.Edit})
Toggle OnChange:
UpdateContext({ChangeDisplayMode: DisplayMode.Edit})
Fields DisplayMode:
If(Toggle1.Value=true,DisplayMode.Edit,DisplayMode.Disabled)
Save button OnSelect:
SubmitForm(Form1);NewForm(Form1)
At the moment when I try to save the form (when those fields are disabled), I don't even get an 'Entry is required or has an incorrect value' error, it just does nothing.

Report
All responses (
Answers (