web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to send all Forms ...
Power Automate
Unanswered

How to send all Forms responses for the last week to a specific email?

(0) ShareShare
ReportReport
Posted on by 5

Hi,

 

I'm having a trouble building the flow mentioned in subject. I'm using Form connected to Excel table. The main issue points: 1) how to select all responses for the last week only (I'm trying to use getPastTime function in KeyValue field in getRow (Excel Online for business element) 2) how to transfer those rows into email (any format - spreadsheet, pdf will be OK).

 

Thanks!

Categories:
I have the same question (0)
  • ChristianAbata Profile Picture
    8,951 Most Valuable Professional on at
    Re: How to send all Forms responses for the last week to a specific email?

    hi @kuznip  please use this expresion to get one week ago date

    getPastTime(1,'Week','yyyy-MM-dd')

     

    the problem with excel is thatwhen you use get items the dates will be converted into a numbers like this.

     

    date.PNG

    Like date in the example, so I recomend you to use sharepoint list to save your date.

  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at
    Re: How to send all Forms responses for the last week to a specific email?

    Hi @kuznip 

     

    The date time type columns get converted to numbers when getting data from excel to Flow. You can refer to this post to understand how to work with date time type data in excel in Power Automate: https://www.bythedevs.com/post/working-with-date-time-data-of-excel-in-power-automate

     

    Once you have the excel rows, you can use the action create html table and create a table from the data and then add that table to the email body and send it. 

     

    Hope this Helps!

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • ChristianAbata Profile Picture
    8,951 Most Valuable Professional on at
    Re: How to send all Forms responses for the last week to a specific email?

    hi @yashag2255  I found another way could you try this

     

    https://www.christianabata.com/2020/04/how-to-get-dates-from-excel-files.html

  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at
    Re: How to send all Forms responses for the last week to a specific email?

    Hi @ChristianAbata 

     

    Are you using any calculation?

     

    Hope this Helps!

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • ChristianAbata Profile Picture
    8,951 Most Valuable Professional on at
    Re: How to send all Forms responses for the last week to a specific email?

    @yashag2255  nop just changing the fotmat column in excel to text.

  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at
    Re: How to send all Forms responses for the last week to a specific email?

    @ChristianAbata  gotcha! So it would be difficult if there are other columns depending on the date and time type data in the sheet. I remember vaguely mentioning about the same on my post but in my opinion it is not a best practice. 

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • kuznip Profile Picture
    5 on at
    Re: How to send all Forms responses for the last week to a specific email?

    Thanks, it was a good advice to format columns with dates as text. However, as a novice, I had many issues on other preceding steps (i.e. - where to enter formula, I didn't understand what are exact outputs, etc.

    As for selecting dates, I simply selected ticks for the date, entered in 'Completion_time' column of Excel (ticks(item()?['Completion_time'])), which were greater or equal to  ticks for last 7 days (ticks(getPastTime(7, 'Day')).

    So, here's the images with the workflow, with some refinement (needed to select specific columns, because @odata.etag and ItemInternalId fields were automatically added, so I got rid of them) and some decoration of emailed table (improved HTLM table visual style):

     

     

    General flowGeneral flow

     

     

    HTML table decorationHTML table decoration

     

    Selecting necessary columnsSelecting necessary columns

  • kuznip Profile Picture
    5 on at
    Re: How to send all Forms responses for the last week to a specific email?

    Hi, @ChristianAbata 

    Thanks, it was a good advice to format columns with dates as text. However, as a novice, I had many issues on other preceding steps (i.e. - where to enter formula, I didn't understand what are exact outputs, etc.

    As for selecting dates, I simply selected ticks for the date, entered in 'Completion_time' column of Excel (ticks(item()?['Completion_time'])), which were greater or equal to  ticks for last 7 days (ticks(getPastTime(7, 'Day')).

    So, here's the images with the workflow, with some refinement (needed to select specific columns, because @odata.etag and ItemInternalId fields were automatically added, so I got rid of them) and some decoration of emailed table (improved HTLM table visual style):

    General flowGeneral flowSelecting necessary columnsSelecting necessary columnsHTML table decorationHTML table decoration

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 532 Moderator

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 461 Super User 2025 Season 2

#3
chiaraalina Profile Picture

chiaraalina 256

Last 30 days Overall leaderboard