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 / PowerApp button to tri...
Power Apps
Unanswered

PowerApp button to trigger flow

(0) ShareShare
ReportReport
Posted on by 321

Hi,

 

I have an App which users submit workitem requests, using a SharePoint list to collect the data. In my SharePoint list I have a choice column for 'Status', there are just two choices either Submitted or Draft.

 

Id like to create a Flow, that when button is pressed will look at the 'Status' column, and delete any items marked 'Draft' that have been created (I will use the Created date) more than for example 30 days ago.

 

So when I press the button, any draft items older than 30 days will be deleted.

 

Thanks

Categories:
I have the same question (0)
  • Akash17 Profile Picture
    Super User 2024 Season 1 on at

    Hi @JimboSey 

    PowerApps  will be trigger

    then Get Item action 

    In get item you can write filter quarry like Status=Draft and Created date is greater than 30

    then use delete item and provide above id from dynamic content

  • v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @JimboSey,

    Do you want to delete all the draft status items that created more than 30 days?

     

    Here is a flow for your reference:

    vqiaqimsft_0-1659599646970.png

     

    formatDateTime(item()['CreatedDate'],'yyyy-MM-dd')
    addDays(utcNow(),-30,'yyyy-MM-dd')

     

    Note that you should select StatusValue from the Dynamic content, and select ID from the Get items tab in the Dynamic content as well.

     

    In addition, since you trigger the flow from Power Apps, you should set the OnSelect property of a button as below:

    YourFlowName.Run()

    vqiaqimsft_1-1659599968768.png

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 392 Most Valuable Professional

#2
11manish Profile Picture

11manish 181 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 112 Super User 2026 Season 2

Last 30 days Overall leaderboard