Changing default value in the From address while composing new emails

Abhinandan Bhan
Tera Expert

Hi,

 

I am able to add new addresses to 'From' field using Email Client Template in CSM workspace.

As you can see in attached image 'From address', I have two email addresses Kunden and Hilfe added to From field where Kunden is default.

 

In other image you can see I have added Hilfe as first email in my Email Client Template.

 

I tried different ways to make Hilfe email as my default email but always end up having Kunden email as default.

 

Do you know a way how I can change the default email address?

2 REPLIES 2

Tim Deniston
Mega Sage
Mega Sage

Have you tried setting the "From" field on the email client template? That may need to be added to the email client template form. 

TimDeniston_0-1693420848218.png

 

7bitew
Tera Expert

I ran into the same issue. It appears that the system returns the addresses in an arbitrary order when using "Select From List".  What I've done is kind of a workaround.

 

Use "Script" as the From Generation Type. This will allow you to determine the query that's used to return the addresses so you can order them for your needs. 

 

For my requirement, I added an Order field to the sys_email_client_from_address table. I also added a choice list field that I can use to assign "ownership" for the email addresses to specific groups to help filter the correct email addresses. You could easily do a query for the specific email addresses instead.

 

Then in my script I do the following:

(function (fromAddressQuery, targetRecord) {
		
		fromAddressQuery.addQuery("u_owner", "Some Owner");
		fromAddressQuery.orderBy("u_order");

})(fromAddressQuery, targetRecord);

 

The orderBy is the important part. This will then allow you to set the ordering of the addresses on the Email Client From Address records.