I have created 2 form in 1 apps, these 2 forms are created for different purposes, so only required to fill in either 1 form.
The submission of the form will have to link into different sharepoint list, does anyone have any ideas on this?
Currently i am using the " SubmitForm(form1) ; SubmitForm(form2)", it seems like not so right in this case.
Appreciate if any could help on this.
Solved! Go to Solution.
Front screen, I assume you have a dropdown the user selects the option
Set(UserSelection, Dropdown1.Selected.Value); Navigate(EditScreen1);
In the Edit screen, Set the Form visibility based on the selection
Set Visible property of Form1 to
UserSelection="Option 1"
Set the Form 2 Visible property to
!Form1.Visible
In the Submit button
If(UserSelection="Option 1",
SubmitForm(form1),
SubmitForm(form2)
)
Hi @Yan91
As you said, you have the logic to use either of the forms. We can use the same logic white submitting.
Set the OnSelect property of the submit button to
If(condition,
SubmitForm(form1),
SubmitForm(form2)
)
Note: Update the condition based on how to determine which form
In your case, I would use the built in capabilities of the form to control the submit.
So, on Form1, set the OnSuccess action to : SubmitForm(Form2)
Then change your original formula to : SubmitForm(Form1)
This way, if the first submit is successful, then the form will automatically submit the second form.
Now, not sure from your statement if the fact that you have 2 forms, that a user will fill in one or the other, or if the user is only filling in one form, but the second form needs to submit as well.
If that is the case, the approach would be a little different, and you would want to utilize logic to determine which form was chosen to be completed and then submit that and then the second.
So perhaps clarify a little more on the scenario if the above is not helpful or what you need.
I hope this is helpful for you.
It is only one of the form are required to be fill in, the another one can be leave blank and only submit the form which have been completed.
Would you please help on the logic to determine which form are required to be choose and completed?
Hi @Yan91
You mentioned, User will be filling in only one form. Can you share the logic/condition? Is it based on form data or the user input?
In the front page, there are 2 options for user to choose and will navigate them into form. It depends on user selections, then user only required to fill in that form and submit.
Front screen, I assume you have a dropdown the user selects the option
Set(UserSelection, Dropdown1.Selected.Value); Navigate(EditScreen1);
In the Edit screen, Set the Form visibility based on the selection
Set Visible property of Form1 to
UserSelection="Option 1"
Set the Form 2 Visible property to
!Form1.Visible
In the Submit button
If(UserSelection="Option 1",
SubmitForm(form1),
SubmitForm(form2)
)
User | Count |
---|---|
164 | |
96 | |
78 | |
73 | |
59 |
User | Count |
---|---|
204 | |
166 | |
98 | |
94 | |
79 |