cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
blackandgold
New Member

Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

Hi,

 

Stuck on generating a flow that will send out an email based on a SP calculted date.

 

The below works, but it uses a manual date within the SP list ('Review date manual'). If I change it to the calcluated list tem in SP ('Review Date') that adds 180 days from 'date added' it fails. So I need the flow to accept/recognise the calculated date or Flow to add 180 days to the 'date added' list item and then send the email (s).

 

The expression used is:  formatDateTime(utcNow(), 'yyyy-MM-dd') which sends out an email if list item equals today's date. Idealy dynamic content should use the calculated SP item ('Review Date').

 

Flow1.png

 

Flow2.png

8 REPLIES 8
Dual Super User
Dual Super User

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

Hi @blackandgold 

 

Microsoft flow will not intepret SP calculated columns since they are calulcated at run time

 

You would have to add the calculattion logic within flow

so if you need to add 180 days to a particular date field then use expression

adddays(datefield,180)

 

Regards,

Reza Dorrani

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

blackandgold
New Member

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

Thanks. But where should this go. Does it need to be?

 

Action:Compose - 'date' field

 

Condition: adddays(datefield,180) 'is equal to' formatDateTime(utcNow(),'MM-dd')

Dual Super User
Dual Super User

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

@blackandgold 

 

Since review date has logic to have 180 days added to created date

 

on review date use expression

 

adddays(dynamiccontentreviewdate,180)

 

blackandgold
New Member

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

Thanks again, but I'm unable to add dynamic content within that bracket. 

 

I did try the following, that didn't work. 

 

Flow3.png

 

 

 

 

Dual Super User
Dual Super User

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

Hi @blackandgold 

 

In the expression window,

 

type adddays( - then switch to dynamic content and pick the column

then switch baack to expression and coninue  with ,180)

 

 

blackandgold
New Member

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

I've looked on here and either you have an updated version of Flow (or license) or something is wrong as I can only select the following(see image below). Some responses suggest this feature is not available whereas others say it is (inserting a DC into an expression).

 

Whereupon I tried the following as I could not select the SP item I wanted: 

addDays (outputs('Get_items')?['DateAdded']),180)

 

Flow4.png

Highlighted
Dual Super User
Dual Super User

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

@blackandgold 

 

do 

addDays (item()?['DateAdded']),180)
blackandgold
New Member

Re: Flow to send email 180 days (6 months) from a either a calculated SP list item or for Flow to adddays (180) to date entered on SP list

 


@RezaDorrani wrote:

@blackandgold 

 

do 

addDays (item()?['DateAdded']),180)

Thanks, however I get:

 

'The expression is invalid.' 

 

This should be simple to achieve - are there differences beteen free version (with license) and paid version? Otherwsie what am I missing...

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (8,595)