Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

When a date is entered or modified in a sharepoint record, update a field showing a date showing 5 days from originally entered date

(0) ShareShare
ReportReport
Posted on by 2

Hello.  Here is what I would like to do.

 

When date is entered or modified in Day0

  • If TestID contains the letters HRC anywhere in it:
    • Update FirstTestDue to show date Day0 + 5 days (In example below I want it to populate with 1/31/2022)
    • Update SecondTestDue to show date Day0 + 8 days (Example below should be 2/3/2022)

flow table.png

Here is my flow so far:

 

 

 

 

 

 

 

 

addDays(triggerOutputs()?['body/_x0044_ay0'],5,'MM/dd/yyyy')

 

 

 

 

 

 

I'm quite new to this so any help would be much appreciated.

 

Thank you

  • v-yujincui-msft Profile Picture
    on at
    Re: When a date is entered or modified in a sharepoint record, update a field showing a date showing 5 days from originally entered date

    Hi @npsEDU ,

     

    I agree with what @Mister_Shaik  said, here is another way for your reference. You might consider using calculated columns in SharePoint.

    https://docs.microsoft.com/en-us/previous-versions/office/developer/sharepoint-2010/bb862071(v=office.14)

    vyujincuimsft_0-1643348621828.png

    =IF(ISERROR(FIND("HRC",TestID)),DATE(YEAR(Day0),MONTH(Day0),DAY(Day0)),DATE(YEAR(Day0),MONTH(Day0),DAY(Day0)+5))
    =IF(ISERROR(FIND("HRC",TestID)),DATE(YEAR(Day0),MONTH(Day0),DAY(Day0)),DATE(YEAR(Day0),MONTH(Day0),DAY(Day0)+8))

    vyujincuimsft_1-1643348690132.png

    vyujincuimsft_2-1643348731294.png

    Result:

    Caculated.gif

     

    Best Regards,

    Charlie Choi

  • Mister_Shaik Profile Picture
    1,006 on at
    Re: When a date is entered or modified in a sharepoint record, update a field showing a date showing 5 days from originally entered date

    Hi @npsEDU ,

     

    What you're doing is basically correct, but only assuming that the "FirstDueDate" and "SecondDueDate" fields are Single Line text fields. 

     

    If those fields are date fields, then you don't need to specify the format, you can just add the number of days to Day0 date and use it to update the fields.

    addDays(outputs('Get_item')?['body/OData__x0044_ay0'],4)

    2. action.PNG

    1. list output.PNG

     

     

    Hope you find this helpful! 🙂

     

    Kind Regards,

    Shaik Sha
    ________________________________________________________________________

    If I have answered your question, please mark the post as Solved.
    If you like my response, please give it a Thumbs Up.

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1