cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ukteacher
Regular Visitor

Time and Date Expression Help Needed

Hi everyone,

I am quite new to Power Automate and have no experience in expression writing or coding so I would really appreciate some help.

 

The action that I am struggling with is:

I need a flow that will send an email IF the date submitted as an answer to a question in a MS form is less than 90 days before a specified date in the future (02/09/2021).

 

I have:

  1. When a new MS Form response is submitted
  2. Apply to each
  3. Get response details
  4. Condition (This is what I am stuck on... just not sure how to write the condition)
  5. If yes
  6. Send an email (V2)

Any help would be greatly appreciated.

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-LilyW-msft
Community Support
Community Support

Hi @ukteacher 

Has your problem been solved?

Do you want to send the email when '2021-09-02' subtract the date submitted as an answer to a question in a MS form is less than 90? 

If yes,you can refer to the screenshot below.

This is my test From

vLilyWmsft_4-1628488668441.png

Flow in details:

vLilyWmsft_0-1628488291868.png

vLilyWmsft_1-1628488307757.png

vLilyWmsft_2-1628488328054.png

Expression:div(sub(ticks('2021-09-02'),ticks(outputs('Compose'))),864000000000)

vLilyWmsft_3-1628488586122.png

When I submit From with the date(2021-08-09), Flow will send an email to the submitter.

vLilyWmsft_5-1628488927412.png

vLilyWmsft_6-1628488953323.png

Hope the content above may help you.

Best Regards

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

 

View solution in original post

4 REPLIES 4
Powerplatform01
Post Patron
Post Patron

@ukteacher 

You can watch this video.Also request you to please subscribe this channel

https://youtu.be/NLEMPn-T3ns

ukteacher
Regular Visitor

@Powerplatform01
Thank you for taking the time to reply.


I'm sorry but that doesn't really help me with my problem...
I'm really new to this.

@ukteacher 

Ok will check again.meanwhile please subscribe my channel

It helps me to motivate you further

 

https://youtu.be/NLEMPn-T3ns

v-LilyW-msft
Community Support
Community Support

Hi @ukteacher 

Has your problem been solved?

Do you want to send the email when '2021-09-02' subtract the date submitted as an answer to a question in a MS form is less than 90? 

If yes,you can refer to the screenshot below.

This is my test From

vLilyWmsft_4-1628488668441.png

Flow in details:

vLilyWmsft_0-1628488291868.png

vLilyWmsft_1-1628488307757.png

vLilyWmsft_2-1628488328054.png

Expression:div(sub(ticks('2021-09-02'),ticks(outputs('Compose'))),864000000000)

vLilyWmsft_3-1628488586122.png

When I submit From with the date(2021-08-09), Flow will send an email to the submitter.

vLilyWmsft_5-1628488927412.png

vLilyWmsft_6-1628488953323.png

Hope the content above may help you.

Best Regards

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

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (4,277)