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
AMAN SINGH 24AMAN SINGH 24 

On Account object i want a checkbox if it is checked after saving redirect to some visualforce page

GauravGargGauravGarg

Hi Aman,

Create a checkbox type field, and in trigger write a code to Page.Redirect to redirect account page to some VF page. Below is the article to use Page Redirect:

http://salesforce.stackexchange.com/questions/99950/redirect-to-a-page-from-apex-in-the-constructor

Hope this helps.

Thanks,

Gaurav

AMAN SINGH 24AMAN SINGH 24
Can we do without any coding?
GauravGargGauravGarg
Hi Aman,

We can use JavaScript Detail button to achieve this. 

http://stackoverflow.com/questions/16562577/how-can-i-make-a-button-redirect-my-page-to-another-page

Thanks,
Gaurav
AMAN SINGH 24AMAN SINGH 24
hello 
But on a standard page, we cannot write javascript.
I have to do without apex or vf page. Is there anyway?
 
 
 
GauravGargGauravGarg
Hi Aman,

Please override Save button with "execute Javascript" and write code within that button. 

Thanks,
Gaurav
AMAN SINGH 24AMAN SINGH 24
hello
would you please give the code and steps
thanks in advance