Comments on: Send an Email Notification with Associated Attachments https://servicenowguru.com/scripting/send-email-notification-attachments/ ServiceNow Consulting Scripting Administration Development Wed, 06 Mar 2024 21:08:09 +0000 hourly 1 https://wordpress.org/?v=6.8.2 By: Scott https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6704 Thu, 04 Jul 2013 03:50:56 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6704 sort along the same lines but…. is there a way to configure an email notification that has an attachment on it. when the email notification is triggered dependent on its conditions, it sends the email notification and the attachment to the recipient.
storyline to this is, a record producer on the Service Cat, user fills out the form and submits it, this triggers an email notification (that has a built in attachment) to the “send to:” person or group.

im not looking for the user to attach anything to the record producer at the time of filling it in and I’m not trying to send any attachment that may be on the “INC” or “REQ”, just want to configure an email notification that has a built in attachment and send that.

]]>
By: Martijn https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6703 Thu, 14 Mar 2013 14:25:56 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6703 Yes, I found that. In Notifications you can select if you want attachments to be sent, too (“include attachments option”… who would guess ;-))
However, another option I found is to copy the attachment to the sys_email record before it is sent and then the attachment will be added to the email, too.

]]>
By: Mark Stanger https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6702 Thu, 14 Mar 2013 12:46:12 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6702 In reply to Martijn.

Check out the green notice in the article above. You can define this with a per-notification checkbox if you want to include the actual attachments.

]]>
By: Martijn https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6701 Thu, 14 Mar 2013 09:41:04 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6701 In reply to Jim Coyne.

Did you update the url?
gs.generateURL(gr.getTableName(),gr.sys_id):
the “getTableName” may send you the wrong table, so the URL will not be determined properly (make sure it is “change_request ” and not “incident”).

A question that I have: how do I really send out attachments? These are just links and the user receiving these emails still has to log into ServiceNow to read them. There are cases where you don’t want this.

]]>
By: Jim Coyne https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6700 Thu, 28 Oct 2010 21:18:31 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6700 In reply to Mark Stanger.

Of course – “current.sys_id” is not what I want, but the sys_id of the actual request.

]]>
By: Mark Stanger https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6699 Thu, 28 Oct 2010 09:16:32 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6699 In reply to Jim Coyne.

Just tested this at https://demo.service-now.com and it seems to work fine there on the change request table. I’ve got a notification set up there called ‘Test change attachments email’ that you can use for comparison purposes. The other thing I would try would be to put some ‘gs.log’ statements in the script to see if it is being executed, ‘current.sys_id’ matches the sys_id of the change request, and if your GlideRecord query is returning any attachments.

]]>
By: Jim Coyne https://servicenowguru.com/scripting/send-email-notification-attachments/#comment-6698 Thu, 28 Oct 2010 08:52:47 +0000 https://servicenowguru.wpengine.com/?p=1157#comment-6698 I have this working for incident notifications, but for some reason the attachments will not appear in a change request notification. Added the code to the email template but it simply will not display the attachments.

]]>