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
MN_sfdcMN_sfdc 

How to open a custom lightning modal from detail page using button or link?

Hi All,
My requirement is to open a custom lightning modal from the detail page and do the business logic. Like the following New Contact standard modal using button.
Example

Thanks in advance
Best Answer chosen by MN_sfdc
Prady01Prady01
hi, You can create a standard OOTB saleforce action.

1) Create a cusotm action.
2) Select appropriate behaviour.
3) Add fields to action layout.
4) Pre-populate fields by defining them in the quick action.


Hope this help!
Prady01

All Answers

ShirishaShirisha (Salesforce Developers) 
Hi,

Greetings!

Can you please check the below document for the sample code to open the lightning model from record detailed page:

https://salesforce.stackexchange.com/questions/294762/modal-pop-up-on-standard-lightning-record-detail-page

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future.

Warm Regards,
Shirisha Pathuri
MN_sfdcMN_sfdc
Hi Shirisha,
Thanks for the quick reply, but it is saying to create the lightning component and place it to the record detail page and do the stuff. 

But my requirement is different. By using a button or link, I Have to open a modal for doing stuff like a standard functionality.
Prady01Prady01
hi, You can create a standard OOTB saleforce action.

1) Create a cusotm action.
2) Select appropriate behaviour.
3) Add fields to action layout.
4) Pre-populate fields by defining them in the quick action.


Hope this help!
Prady01
This was selected as the best answer
Thomas Sanders 1Thomas Sanders 1
Your topic selection is really impactful this time as my https://assignmentjunkie.co.uk/buy-coursework team head assigned me the same topic for online presentation. You have just fixed my all trouble just in one go. Thank you.
Alex Baker 5Alex Baker 5
Everyone wears a costume every single day. You can dress up as your favorite person or superhero any day, but Halloween is something special. You can search for adult halloween costume ideas (https://www.jacketsinn.com/halloween-costumes-deals/) online.