(function runMailScript(/* GlideRecord */ current, /* TemplatePrinter */ template, /* Optional EmailOutbound */ email, /* Optional GlideRecord */ email_action, /* Optional GlideRecord */ event) { var rmb = new global.RenderMai

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2019 03:20 PM
Greetings Everyone, I've been messing around with this for a few hours, it's starting to drive me nuts. Can someone be so kind as to tell me how I can have text in the Body of the Outlook message this script below will open when the icon is clicked.
Thanks
Robert
(function runMailScript(/* GlideRecord */ current, /* TemplatePrinter */ template,
/* Optional EmailOutbound */ email, /* Optional GlideRecord */ email_action,
/* Optional GlideRecord */ event) {
var rmb = new global.RenderMailtoButton();
var img = "reject.png";
var response = "reject";
template.print(rmb.renderMailtoButton(img,response,'100px'));
})(current, template, email, email_action, event);
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2019 03:30 PM
Hi,
Do you want to open a new email message upon click of the icon or wanted to redirect user to a web page?. if you want to open a new page, then you have to use mailto: or if you want to have a hyperlink then you have to use anchor tags in html

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2019 04:28 PM
Right now, That script will open a new email message and populate the Subject, but I'm having issues having it place text in the Body. thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2019 04:42 PM
Hi,
You may try something like below
<a href="mailto:someone@example.com?Subject=Hello%20again&body=Your%20suggestions%20are%20really%20important"
target="_top">Send Mail</a>
If possible, please share your script and what exactly the issue

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2019 05:04 PM
The script I'm using is below, everything works, just having a hell of time figuring out how to populate text in the body of the email that opens open.
(function runMailScript(/* GlideRecord */ current, /* TemplatePrinter */ template,
/* Optional EmailOutbound */ email, /* Optional GlideRecord */ email_action,
/* Optional GlideRecord */ event) {
var rmb = new global.RenderMailtoButton();
var img = "reject.png";
var response = "reject";
template.print(rmb.renderMailtoButton(img,response,'100px'));
})(current, template, email, email_action, event);