I have created a lighting component and used it in a visualforce page by using lighting out. Is there any way to display the toast message?


From Salesforce docs:

e.force:showToast event is handled by the one.app container. It’s supported in Lightning Experience, Salesforce app, and Lightning communities.

It doesn't say anything about classic or VF, so my best guess is You have to manually implement toast using SLDS.

Src: https://developer.salesforce.com/docs/component-library/bundle/force:showToast

| improve this answer | |
  • 3
    My usual tactics are to just try to fire a default toast, and if that fails, an alert. However, you're absolutely correct, one could easily build a custom toast component to use in other places. – sfdcfox Jan 17 '19 at 13:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.