Create excelsheet from scipt

prashant8
Tera Expert

Hi everyone hope you doing well,

I have a requirement -

send a notification to assigned_to(user select in assigned to),

Email(notification) should include all incident (with same assigned_to & state= in progress),

& these incident should be in an excel sheet format.

Thanks 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

you will have to store file to that incident record and include that in email

So just before triggering the email write script to generate excel. I would suggest to use CSV as it's easy

then trigger the email using gs.eventQueue()

Generate CSV file through script

Regards
Ankur

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

View solution in original post

7 REPLIES 7

Hi its showing only one incident in email, i want all emails assigned to that person with state(in progress)

 

Hello Prashant,

I have checked and found that in my case if it attaching file to email containing all incident assigned to particular user.

Please also put the condition on the BR in script condition field so that the BR get triggered only for specific notification and not for all notification.

find_real_file.png

Thanks

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

you will have to store file to that incident record and include that in email

So just before triggering the email write script to generate excel. I would suggest to use CSV as it's easy

then trigger the email using gs.eventQueue()

Generate CSV file through script

Regards
Ankur

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