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 Automate / Duedate but will not b...
Power Automate
Answered

Duedate but will not be counted on Saturday and Sunday

(0) ShareShare
ReportReport
Posted on by 40

Dear All,

When submitting the form, the process will planner create a task with a duedate of 3 days, but if it is Friday, it will not be charged on Saturday and Sunday, but will be charged on Friday, Monday and Tuesday. Thanks you.

Categories:
  • Pstork1 Profile Picture
    69,665 Most Valuable Professional on at

    Try the following formula.  Replace Datepicker with the field for your duedate.

    If(Weekday(DateAdd(DatePicker1.SelectedDate,3,Days))<2,
    DateAdd(DatePicker1.SelectedDate,4,Days),
    Weekday(DateAdd(DatePicker1.SelectedDate,3,Days)) >6,
    DateAdd(DatePicker1.SelectedDate,5,Days),
    DateAdd(DatePicker1.SelectedDate,3,Days))
  • Verified answer
    v-bacao-msft Profile Picture
    Microsoft Employee on at

    Hi @giangnguyen ,

     

    Do you mean Submission Time as Start Date, then add three days as Due Date and exclude weekends day?

    You could refer to the following method to configure Flow.

    • Initialize three variables, Date is used to indicate the date that may be included in the task, Number is used to control the loop, and the last variable is used to record valid Dates.
    • Use dayOfWeek() function to exclude Saturday and Sunday and append the valid date to the array.
    • Each loop requires a day plus of Date.

    Expression reference:

     

    formatDateTime(body('Get_response_details')?['submitDate'],'yyyy-MM-dd')
    dayOfWeek(variables('Date'))
    addDays(outputs('CurrentDate'),1,'yyyy-MM-dd')

    Image reference:

     

    4.PNG

    Details of Apply to each:

    5.PNG

    Details of Do Until:

    7.PNG

    Details of Condition:

    8.PNG

    Please take a try.

     

    Best Regards,

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 Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 330

#2
11manish Profile Picture

11manish 282 Super User 2026 Season 2

#3
Henil Profile Picture

Henil 123

Last 30 days Overall leaderboard