cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cyberco01
Post Partisan
Post Partisan

Powerapps Form - button to skip the submit

Dearies,

 

I have powerapps forms linked to a Sharepoint List.

I have a button in the form - in this button I have a code to submit and also a workflow runs that creates a folder in Sharepoint Document Library with a naming format - the name format has "ID" as one the parameter.

Also, on submit of form (SAVE on top of form) I have another workflow that sends mail to department head for approval.

 

Is there any way I can avoid the submit on the button. Am I going in the right direction.

Kindly help.

8 REPLIES 8
yashag2255
Dual Super User II
Dual Super User II

Hi @cyberco01

 

For stopping the form to get submitted, please remove SubmitForm(<YourFormName>) from the OnSelect property of your button and this won't save the form and will just trigger the workflow.
 
If this doesn't solve your issue, please share the screenshot along with the expression so that we can help you better.
 
Do you want to just have independent actions for the workflow and the submit/save forms? 
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Below is the button code for my form. I need this button to create a new folder in Sharepoint Document Library with SP form automated ID as one of the parameter in Folder Name.

In order to get ID i submit the form through this button, this button triggers one workflow and creates a folder in the Sharepoint Document Library.

SubmitForm-SP.PNG

 

Also, on SAVE click of the form, i have another workflow to send for approval to Dept Head.

ActualForm.PNG

Hi @cyberco01 , 

 

Understood. So from which button do you want to remove the functionality of form submit? 

It is advised that you do not try to amend this on the SAVE button on the SharePoint one (the button in the second screenshot) However, you can create another button on the form to trigger the other workflow if you want to keep the actions independent on the SAVE button. 

 

Hope this Helps.

Hi @yashag2255 ,

 

I want to remove the submit functionality from 'Create Folder' button. At the same time, this button must trigger the workflow that creates a folder in Sharepoint Document Library. Without submitting i wont get the ID, so i put the submit function in this button.

Both my workflows are independent, but triggered on Form submit.

Hi @cyberco01 , 

 

So as I understand, you want to triger a workflow on the edit form: I mean, you will first create the item and save it and then on the edit form you want to submit/trigger the approval? 

 

If so, please remove the "SubmitForm(SharePointForm1);" from the OnSelect property of the button. You might want t consider renaming the button to submit for approval. 

 

Doing this, will just trigger the workflow when the button is pressed. 

 

Hope this Helps! 

Hi @yashag2255 ,

 

You want to triger a workflow on the edit form: I mean, you will first create the item and save it and then on the edit form you want to submit/trigger the approval --->>> Yes true.

 

But, need 2 triggers to happen - one trigger for approval to Dept Head on Save/Submit of form and another trigger for folder creation through button click.

Hi @cyberco01 

As fas as I know, you cannot get the ID of record unless you submit the form. But if you want to save/assign any number in file name while you clicking on "Create Folder" action, you can do it by a number of ways.

 

My thought:

 - you can create a seperate list which is having only 1 field with latest number incrementated whenever user clicked "Create Folder" button and then use this value in folder name.

 

 

Anonymous
Not applicable

Hi @cyberco01 how are you progressing with this? 

 

@Anonymous 

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (2,012)