How to attach Excel as attachment in Notification

Dharaneetharan
Tera Contributor

I have a requirement to send an email with an excel attachment containing the records based on a query in a custom table.

 Detailed Explanation:

1) Email should be triggered to Department head after 35 days when users in that department doesn't made response to tasks in custom table.

2)There are multiple departments and each department head to receive an email with attachment containing the users from their department.

 

Kindly advice if there is a way to achieve this.

1 ACCEPTED SOLUTION

Hello @Dharaneetharan 

 

Sorry, I forgot to share the document. 

How to generate excel file from a script in Servic... - ServiceNow Community

 

Here, you can refer. 

 

Kindly mark my answer as helpful and accept solution if it helped you in anyway. This will help me be recognized for the efforts and also move this questions from unsolved to solved bucket. 

 

Regards,

 

Shivalika 

 

My LinkedIn - https://www.linkedin.com/in/shivalika-gupta-540346194

 

My youtube - https://youtube.com/playlist?list=PLsHuNzTdkE5Cn4PyS7HdV0Vg8JsfdgQlA&si=0WynLcOwNeEISQCY

View solution in original post

10 REPLIES 10

Ankur Bawiskar
Tera Patron
Tera Patron

@Dharaneetharan 

you cannot generate excel as an attachment and add to record

why not use CSV?

how is your flow configured to run now?

you can use custom flow action and use script to create CSV file and then attach it to your record and then send email using Notification and in that notification use "Include attachment" checkbox

Generate CSV file through script

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader