Email client - UI actions which populate the "to" field

sdhar
Kilo Contributor

Is it possible to make two different UI actions which put different values in the TO field on the Case email client?

I know that there is one email client template per table, but I have attempted to work around this by creating a UI action which sets a field and then opens the email client, where the template is reading that field. However I'm having trouble combining the server-side code with client side and then opening the email client on top of that.

Thanks for your help.

1 ACCEPTED SOLUTION

Use the solution provided in below thread

https://community.servicenow.com/community?id=community_question&sys_id=660e6edadb7f1b04fece0b55ca96...


Please mark this response as correct or helpful if it assisted you with your question.

View solution in original post

11 REPLIES 11

The second  solution is actually what I'm attempting now, but I'm having trouble coming up with UI action code which can both set custom field and open the email client. I will look into quick messages though.

You can try g_form.setValue('custom field',new recipient) and g_form.save() and then call emailClientOpenpop('your_table_name')


Please mark this response as correct or helpful if it assisted you with your question.

hmm, I tried this but nothing seems to happen - the field doesn't get set, the email client doesn't pop up... Attached is my UI action:

 

Also thanks for your help.

Try this instead

 

g_form.setValue('u_destination_email',current.customer_email);
emailClientOpenPop(this,'sn_customerservice_case');


Please mark this response as correct or helpful if it assisted you with your question.

Please close the thread my marking the above response correct if it worked for you


Please mark this response as correct or helpful if it assisted you with your question.