A feature missing from the standard Salesforce record edit functionality is the ability for the user to confirm that they wish to execute an action. If a user inadvertently clicks on the Cancel button, their work will be discarded.
In this recipe we will create a Visualforce page that allows a user to create an account record. If the user clicks on a button to save the record or cancel the creation, they will be requested to confirm that they wish to continue with the action.
Navigate to the Visualforce setup page by clicking on Your Name | Setup | Develop | Pages.
Click on the New button.
Enter
Confirmation
in the Label field.Accept the default Confirmation that is automatically generated for the Name field.
Paste the contents of the
Confirmation.page
file from the code download into the Visualforce Markup area and click on the Save button.Navigate...