1

I want to create a workflow for Change Management list(Items are added by filling the form in it), which will send notifications at the end of the each month and the report can be any file (List, PDF), which also sends email notifications at the end of the month to the Manager.

The requirements of the report are as follows:

E.g, No. of Forms submitted in January 2020 E.g, Per department Forms submitted.

Etc.

Thank you very much.

  • Which type of file and what details do you need in the file? – harshal gite Feb 3 at 11:46
  • I want to create a workflow for Change Management list(Items are added by filling the form in it), which will send notifications at the end of the each month and the report can be any file (List, PDF), which also sends email notifications at the end of the month to the Manager. The requirements of the report are as follows: E.g, No. of Forms submitted in January 2020 E.g, Per department Forms submitted. Etc. Thank you very much. – Noman Feb 3 at 14:58
  • Ok. Which version of SharePoint are you using? – harshal gite Feb 4 at 4:36
  • Hi @Harshal, I am using sharepoint 2013 online and also I have SharePoint Designer 2013 – Noman Feb 4 at 9:58
  • You need to use power automate to create a flow to attach files in emails. SharePoint Designer workflows don't allow attachments to emails. – harshal gite Feb 4 at 10:01
2

Follow the steps below:

  1. Create a Scheduled flow which will give you a trigger named "Recurrence". In that change interval to 1 and frequency to Month.
  2. Then add 2 actions - Initialize Variable and add formula in both as shown below:

    formatDateTime(startOfMonth(utcNow()), 'yyyy-MM-ddTHH:mm:ssZ')

enter image description here

formatDateTime(addDays(concat(add(int(formatDateTime(utcNow(),'yyyy')),if(equals(formatDateTime(utcNow(),'MM'),'12'),1,0)),'-',add(int(formatDateTime(utcNow(),'MM')),if(equals(formatDateTime(utcNow(),'MM'),'12'),-11,1)),'-01T00:00:00Z'),-1), 'yyyy-MM-ddTHH:mm:ssZ')

enter image description here

This will give you start and end dates for the current month which will be used in the next step to get data from SharePoint.

  1. Add action to get items from your SharePoint list as shown below. enter image description here

    1. Now you have your data as output from the above get items action. You can manipulate it however you want using loop. Add an action to create a file (saved on SharePoint or anywhere) and then add action to send email and attach this file to the email.
| improve this answer | |
  • Awesome. You are a legend bro thank you very much. I am struggling with doing the next step like creating a file and then attaching that to the email. Can you please show me like this. How would I be able to do this. As I have created the SharePoint document library where the reports will be saved. Thanks again man. – Noman Feb 4 at 14:05
  • Hi Noman, It's a bit lengthy and I'm short on time. Will try to create whenever I have enough time. Till then try to create something like this in your existing flow - wonderlaura.com/2019/01/09/microsoft-flow-quick-parts – harshal gite Feb 5 at 6:08
  • Hi Harshal, Thanks for sending the links though. Can you please whenever you have time, you can show me that'll be very great – Noman Feb 5 at 9:35
  • As I am new so find it a difficult to do first time and once I will learn then I'll be good in it. – Noman Feb 5 at 9:36
  • waiting for you bro – Noman Feb 6 at 12:08
1

If you're working in SharePoint Online you can create a Flow in Power Automate.

Navigate to Power Automate, click Create in the left-hand navigation. From the 4 choices of Flow type, choose scheduled and set up a monthly recurrence (similar to Outlook meetings) and then it creates a blank flow. Then use other conditions and actions to build the logic and make it do what you want.

I hope this helps and enjoy playing with Power Automate!!

| improve this answer | |
  • Thank you for your answer @Keegatron thank you. Can you please tell me the conditions as well like how the flow will count the list items which has been created in specific time please. – Noman Feb 4 at 9:50
  • I mean if I want to get the count of items from the last 30 days. How would we be able to do this? – Noman Feb 4 at 9:57
  • I'm not that proficient in Power Platform but as a guess, you'd first perform a "Get Items" action against the list, then the action after that looks at the Date Created for the items to give you only the items created in the last month and then perform a count on those items, then maybe group them by some other column e.g. Department. All of these are "steps" or "actions" in the Flow but again I'm not that familiar with the various operations and configuring them – Keegatron Feb 6 at 10:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.