- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2019 02:44 PM
Hello all,
I want to include an attachment in our "request completed" email notification. I have uploaded the attachment to the email notification and selected the "Include Attachments" checkbox, but it isn't being uploaded. I thought it was suppose to simple and "include attachments" would attach it but thats not the case. Am I misunderstanding how this checkbox works or does anyone know another way to accomplish this?
Thanks,
Grace
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2019 08:10 PM
Hi gnunez,
You can pick up and attach the notification physical attachment to the actual email with a Business Rule on sys_email table:
Before - Insert
Condition:
Subject Starts with = Your subject (or as per your requirement when this BR should run and attach the attachment),
var attachment = new GlideRecord('sysevent_email_action');
if(current.subject == "your email subject"){
attachment.addQuery('name', 'Your notification name');
}
attachment.query();
while (attachment.next()) {
strTemp = attachment.sys_id.toString();
GlideSysAttachment.copy('sysevent_email_action', strTemp, 'sys_email', current.sys_id);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2019 04:37 PM
Hello,
Thanks for the reply. I added the attachment to the email notification thinking it would be added to the email. How can I get this attachment added to the record when closed and completed?
Thanks,
Grace
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2019 10:26 PM
Hi,
The only way you can do this is by attaching the document with the specific record and then selecting option "Include attachments" with notification.
Kindly mark correct or helpful if it helps you to solve your problem.
Thank You,
Ashvini k
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2019 04:38 PM
Hello,
Thanks for the reply. I added the attachment to the email notification and selected "include attachments", but it wasn't attached. How can I get this attachment added to the record when closed and completed?
Thanks,
Grace
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2019 08:10 PM
Hi gnunez,
You can pick up and attach the notification physical attachment to the actual email with a Business Rule on sys_email table:
Before - Insert
Condition:
Subject Starts with = Your subject (or as per your requirement when this BR should run and attach the attachment),
var attachment = new GlideRecord('sysevent_email_action');
if(current.subject == "your email subject"){
attachment.addQuery('name', 'Your notification name');
}
attachment.query();
while (attachment.next()) {
strTemp = attachment.sys_id.toString();
GlideSysAttachment.copy('sysevent_email_action', strTemp, 'sys_email', current.sys_id);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-18-2019 02:59 PM
Thank you so much Sam! This is exactly what I was looking for and it worked perfectly!
-Grace 🙂
