Email button using ui macro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-21-2024 12:02 AM
Hi all,
I was having a ui macro button when clicking on the button it will open with the email template filled with short description and to field
But after the instance upgrade the issue i have noticed is the email template is filled with short description but the to field value is not populating. can anyone help me how to fix the issue
The below is the ui macro script:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-21-2024 12:14 AM
Hi @Community Alums,
Can you please try the below code and let me know if it helped you or not?
<?xml version="1.0" encoding="utf-8"?>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide">
<g:sc_button id="email" title="email" label="email" onclick="return openEmail()" />
<script language="javascript">
function openEmail(){
var uniqueValue = g_form.getUniqueValue();
var tableName = g_form.getTableName();
popupOpenEmailClient("email_client.do?sysparm_table=" + tableName + "&sysparm_sys_id=" + uniqueValue + "&sysparm_uniqueValue=" + uniqueValue + "&U_table.u_choice_field=u_choice_value");
}
</script>
</j:jelly>
Please mark this correct if it helped you in any way.
Thanks and Regards,
K. Sai Charan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-21-2024 01:47 AM
It was displaying the error in the popupemailclient i.e., sysparm_sys_id must end with a ";" delimiter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-21-2024 02:21 AM
Hi @Community Alums,
Please update the below line :
popupOpenEmailClient("email_client.do?sysparm_table=" + tableName + "&sysparm_sys_id=" + uniqueValue + "&sysparm_uniqueValue=" + uniqueValue + "&U_table.u_choice_field=u_choice_value");
to
popupOpenEmailClient("email_client.do?sysparm_table=" + tableName + "&sysparm_sys_id=" + uniqueValue + ";" + &sysparm_uniqueValue=" + uniqueValue + "&U_table.u_choice_field=u_choice_value");
Please mark this correct if it helped you in any way.
Thanks and Regards,
K. Sai Charan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-21-2024 03:23 AM
It was showing me the same error