Unable to see Enable for Email Scripting for my Salesforce Custom Object | Community
Skip to main content
Level 2
May 2, 2025
Solved

Unable to see Enable for Email Scripting for my Salesforce Custom Object

  • May 2, 2025
  • 1 reply
  • 962 views

I have synced the scheme for a Salesforce custom object, and I have set up some velocity scripts to pull through the data into an email. The problem I have is the data isn't pulling through. It appears the script is correct, so the suggestion has been to make sure the following is enabled:

 

Enable for Email Scripting and Show in Person Detail:

  • In the Salesforce Object Sync section, make sure that the following settings are enabled:

    • Enable for Email Scripting (This is critical for your Velocity script to work)

    • Show in Person Detail (This ensures the object is visible in the person's record)

 

 

The problem I have, is that I don't see these options in the customer object.

It looks like I am still on a legacy sync, so I don't know how to solve this.

Does anyone know how I can enable these two options for this custom object. 

I am under some time constraints. EEEK.

Thanking you in advance.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SanfordWhiteman

Hi, remember to highlight any code using the syntax highlighter so it’s readable. I edited your post this time.

 

It’s impossible to say if your code is “correct” given that we don’t know what you’re trying to do (arbitrarily seeking the first item in the list is typically not what you want to do).

 

Have you checked off the fields in the tree on the right-hand side of Script Editor? Can you show a screenshot of where you’ve done that?

 

If you’ve done that and dragged one of the fields to the canvas (left-hand side) and it’s shown the list name as  $Commerce_Request__clist, then you should start by dumping the entire list like this:

${Commerce_Request__clist}

 

No reason to start by looping over the list, just dump the list and then go deeper.

1 reply

AdeleB1Author
Level 2
May 2, 2025

It is being suggested that I would not see these options 

 

this is my velocity coding 

#if( $Commerce_Request__clist.size() > 0 ) #set( $request = $Commerce_Request__clist.get(0) ) ${request.CreatedDate} #else No request found. #end

 

when I preview the email for the person record with the custom object it is saying : No request found.

AdeleB1Author
Level 2
May 2, 2025

My salesforce admin has just commented that

 

the lookup fields are on the custom object to the Opp & Contact 

 

But the Opp & Contact doesn't have a lookup back to the custom object 

 

Could this stop the velocity script from pulling through to the email for that Person?