PDI · Question #133
A developer must provide custom user interfaces when users edit a Contact in either Salesforce Classic or Lightning Experience. What should the developer use to override the Contact's Edit button…
The correct answer is A. A Visualforce page in Salesforce Classic and a Lightning component in Lightning Experience. To provide distinct custom edit UIs for Contacts in Salesforce Classic and Lightning Experience, a developer should use a Visualforce page for Classic and a Lightning component for Lightning Experience, overriding the standard Edit button.
Question
A developer must provide custom user interfaces when users edit a Contact in either Salesforce Classic or Lightning Experience. What should the developer use to override the Contact's Edit button and provide this functionality?
Options
- AA Visualforce page in Salesforce Classic and a Lightning component in Lightning Experience
- BA Lightning component in 5alesforce Classic and a Lightning component in lightning Experience
- CA Visualforce page in Salesforce Classic and a Lightning page in Lightning Experience
- DA Lightning page in Salesforce Classic and a Visualforce page in Lightning Experience
How the community answered
(21 responses)- A90% (19)
- C5% (1)
- D5% (1)
Why each option
To provide distinct custom edit UIs for Contacts in Salesforce Classic and Lightning Experience, a developer should use a Visualforce page for Classic and a Lightning component for Lightning Experience, overriding the standard Edit button.
Salesforce Classic supports overriding standard buttons with Visualforce pages. Lightning Experience supports overriding standard buttons with Lightning components (or Lightning web components). This combination allows for a native and optimized custom UI experience in both environments.
Using a Lightning component in Salesforce Classic to override the Edit button is not directly supported; Classic typically uses Visualforce for custom overrides.
A Lightning Page is a flexible page layout for Lightning Experience, but it is not the mechanism used to override a standard button; a Lightning Component is used for that purpose.
Using a Lightning Page in Salesforce Classic for overrides is incorrect, as Lightning Pages are designed for Lightning Experience. While a Visualforce page can technically be used in Lightning Experience, it results in a less native and performant user experience compared to a Lightning component.
Concept tested: Customizing standard button overrides (Classic vs Lightning)
Source: https://help.salesforce.com/s/articleView?id=sf.ui_customize_buttons.htm&type=5
Topics
Community Discussion
No community discussion yet for this question.