web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Run multiple flows wit...
Power Apps
Answered

Run multiple flows with one trigger/button

(0) ShareShare
ReportReport
Posted on by

Is it possible for me to run multiple flows with from one button in Power Apps?

I can't seem to get both flows to run if statement is true, it would either skip the first run or fail the 2nd run.  When it fails, the varID returns blank. Below is the current formula for the OnSelect

 

Set(varID, ThisItem.ID);
If(
 CountRows(DataCardValue1.Attachments) > 0, 
 //true
 SubmitForm(EditItemForm); 'SendNotification'.Run(varID); 'SaveAttach'.Run(varID),
 //false
 SubmitForm(EditItemForm); 'SendNotification'.Run(varID); 
)

 

 

Categories:
  • WarrenBelz Profile Picture
    156,566 Most Valuable Professional on at

    Hi @Tamras ,

    When you say varID returns blank, you have not asked to Flow to return anything, just set varID as the parameter the Flows are asking for. Also where are you running this code from (inside a gallery or form)? What does the SaveAttach Flow do (you have already submitted the form with the attachment card on it?

  • Aethyta Profile Picture
    on at

    @WarrenBelz The button is inside a form. It saves the form and sends the notification. But if there's an attachment, I also want to save it in another library with a date stamp included in the file name.  Below is the SaveAttach flow:
    2021-10-05_13-37-26.png

  • Verified answer
    WarrenBelz Profile Picture
    156,566 Most Valuable Professional on at

    @Tamras ,

    You did not mention the returning varID, so I assume this is simply used to identify the record you want to attach to. You might also try this.

    SubmitForm(EditItemForm);
    Set(varID,EditItemForm.LastSubmit).ID;
    'SendNotification'.Run(varID); 
    If(
     CountRows(DataCardValue1.Attachments) = 0, 
     'SaveAttach'.Run(varID),
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

     

  • Aethyta Profile Picture
    on at

    I can't get the 2nd line to work but when I replaced it with below, it worked fine!  

    set(varID, ThisItem.ID)

      

  • v-xiaochen-msft Profile Picture
    Microsoft Employee on at

    Hi @Tamras ,

     

    If your problem has been solved, you could mark the correct reply as a solution to help others in need. Thanks.

     

    Best Regards,

    Wearsky

  • WarrenBelz Profile Picture
    156,566 Most Valuable Professional on at

    @Tamras ,

    Typo on my response - now fixed - if yours is working, good, but this ensures the ID is the one you just submitted.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • Aethyta Profile Picture
    on at

    I think there's another typo, extra comma in IF statement. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 397 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 354

#3
WarrenBelz Profile Picture

WarrenBelz 232 Most Valuable Professional

Last 30 days Overall leaderboard