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
NaveenReddyNaveenReddy 

How to override new button in Account object.

Can anyone pls give the smaple code to override the "new" button in Account object.

Thanks in advance.


Ankit AroraAnkit Arora
What exactly you need in code? You want to know how you can override the button then it's pretty simple > Create a VFP with standardcontroller = Account

Setup > App Setup > Customize > Account > Button, Links and Actions > Edit the new Button > Select radio of Visualforce Page > and select your newly created page.

Now when you click on new it will redirect to your custom page.