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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Creating a summary ema...
Power Automate
Unanswered

Creating a summary email from a SharePoint calendar using filter array?

(0) ShareShare
ReportReport
Posted on by

Hi,

 

I am trying to create a Flow that looks up the events on a SharePoint calendar and then send an email containing the events for the upcomming day to an email address.  I've been working through the threads on this forum and although I have got further down the road with this I am still hitting an issue.

 

This is what I have so far, the SharePoint calendar has 4 entries, 2 for each day (today/tomorrow at time of testing)

 

calendar.jpg

 

The flow I've created looks like this:

 

emailsummary.jpg

 

The filter array code is:

 

@Equals(formatDateTime(item()?['EventDate'], 'MM/dd/yyyy'), formatDateTime(utcNow(), 'MM/dd/yyyy'))

 

This flow runs without error but the email I get looks like this:

 

emailresult.jpg

 

As you can see it's bringing back all the events?

 

As a side note, if someone can suggest how I can get the time to just show the short time that would also be great.

 

Any thoughts gratefully received.

 

Rob

 

 

 

Categories:
I have the same question (0)
  • Verified answer
    mgiuliani Profile Picture
    21 on at

    Hi Rob,

     

    I built a similar Flow to yours to get the current day's events emailed to me each morning.  The only down side is that I have not figured out how to capture reoccuring events or ones that go multiple days (ie. week off for vacation).  Only the first date registers for those.  I used "Filter Query" under advanced options for the "Get Items" action.  That's what only captures the current day.  I also included how I formatted the time to display in the emails.  The only thing to keep in mind with that portion is if you format your time zone in it, "all day" events will not display as 12:00am to 11:59pm.  Hopefully this gives you some guidance and you can make adjustments as needed.

     

    Filter query: EventDate ge 'utcNow('yyyy-MM-ddT00:00:00Z')' and EventDate lt 'addDays(utcNow(),1,'yyyy-MM-ddT00:00:00Z')'Filter query: EventDate ge 'utcNow('yyyy-MM-ddT00:00:00Z')' and EventDate lt 'addDays(utcNow(),1,'yyyy-MM-ddT00:00:00Z')'Runs successfullyRuns successfullyAs displayed in emailAs displayed in email

    Michael

  • Rob_CTL Profile Picture
    on at

    Hi @mgiuliani

     

    Many thanks for that, I was just looking at the filter query stuff when I got the alert about your reply.

     

    I am going to have a play to see if I can get the all day events to display slightly differently but overall I'm very happy - big thanks.

     

    Have a good weekend.

     

    Rob

  • MattPMoS Profile Picture
    11 on at

    Hi--I'm trying to do something similar, where a Flow sends a weekly automated email including filtered data from a List. I'm very new to Sharepoint so the learning curve is steep. I am stuck because on my "Get Items" step, I can't program in the Filter because "No Dynamic Content is Available".

    I've read some other posts that suggest that the issue is that I'm starting with a Recurrence, but mgiuliani's example is identical to the structure I was mapping out, just with a different date filter, and clearly it is working for them. I'm pretty defeated at this point. Any thoughts on what I'm doing wrong?

  • Rob_CTL Profile Picture
    on at

    @MattPMoS can you post a screenshot of what you currently have?

  • MattPMoS Profile Picture
    11 on at

    Hi Rob and friends--I've actually figured out how to make most of this work, by manually entering the fieldnames in the Expression even when the Dynamic Content wasn't showing (I suspect that at least part of the problem is that I don't fully understand what Dynamic Content is). But with much swearing, trial-and-error, swearing, and plugging in bits and pieces from every Youtube tutorial I could find, I almost have what I want in the email data, except for one annoying thing: Two of the fields in the HTML table are derived from Multiple-Choice columns in the original List, and they are coming over with annoying [""]'s around the data.

    I've read several posts about this but haven't licked it yet. I'll attach screenshots if I can figure out how, right now I'm getting a "do not have permission to upload images" footer. Thanks for your patience everyone, this is a lot harder than teaching about Frogs.

     

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
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard