function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ThimoThimo 

Sending email notification to leads created from web to lead with trial license key

Hi,

 

I want to send out emails from web to lead to the customer - which isn't that problem - but this email should include a unique trial license key. For the key management I would use a custom object, but I don't know how to connect the key to the email (and to this unique user), display it in the mail and send it out.

 

Does anyone have a simple solution for this?

 

 

Thanks in advanced

Thimo

Best Answer chosen by Admin (Salesforce Developers) 
Sonam_SFDCSonam_SFDC

Hi Thimo,

 

I searched but am not able to find an easier way to get this done:

The approach i can think of is:

Create a cross Object Workflow on Lead -

a)which sends an Visualforce email template to lead which will include the license key from the custom object

b)Does a field update on Custom object and marks the key as used(use a field to record usage)

 

The VF template you create will have to search for key which is NOT marked used and then send that to user - if you wish to simplify this, you can:

c)On the same workflow - create a field update that will store the key on the Lead Key Field(custom field)

d)Create an after update trigger on custom object to delete the key once used.

 

 

All Answers

Sonam_SFDCSonam_SFDC

Hi Thimo,

 

Is this Trial License key auto generated?

 

If yes, you can do the following:

-Create an autoresponse template for Web to lead and embed the trial License key field on the template.

-Set the Web to lead autoresponse such that this template goes out to the user with key.

 

ThimoThimo

Hi Sonam,

 

sadly not, auto generated.

It should use one key of a list and this key has to be marked as used for this user to not use it twice or someting.

 

 

 

ThimoThimo

Hi,

 

is there no app or simple way?

 

Sonam_SFDCSonam_SFDC

Hi Thimo,

 

I searched but am not able to find an easier way to get this done:

The approach i can think of is:

Create a cross Object Workflow on Lead -

a)which sends an Visualforce email template to lead which will include the license key from the custom object

b)Does a field update on Custom object and marks the key as used(use a field to record usage)

 

The VF template you create will have to search for key which is NOT marked used and then send that to user - if you wish to simplify this, you can:

c)On the same workflow - create a field update that will store the key on the Lead Key Field(custom field)

d)Create an after update trigger on custom object to delete the key once used.

 

 

This was selected as the best answer