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
Flint LockwoodFlint Lockwood 

Custom Success Message Lightning Action

Hi,

Is it possible to use merge fields in custom success messages in Lightning?
Raj VakatiRaj Vakati
You can able to do it like below

https://developer.salesforce.com/docs/component-library/bundle/force:showToast/documentation
 
showMyToast : function(component, event, helper) {
    var toastEvent = $A.get("e.force:showToast");
    toastEvent.setParams({
        mode: 'sticky',
        message: 'This is a required message',
        messageTemplate: 'Record {0} created! See it {1}!',
        messageTemplateData: ['Salesforce', {
            url: 'http://www.salesforce.com/',
            label: 'here',
            }
        ]
    });
    toastEvent.fire();
}