+ Start a Discussion
Pierre-François CPierre-François C 

visualforce save button return record in edit mode

Hi Everyone,

Do you know how to customize the Save button in a visualforce page, to open the new record created in edit mode, not in view mode (standard) ?
PeaceMakerPeaceMaker
Hi Pierre-Francois C,

You can use custom pagereference method for Save button action and Insert the record through code,  once it is inserted, get the ID and reload the page or redirect the page using as below..

public pagereference CustomSave(){
Insert Record;
return new PageReference('/'+Record.id+'/e');
}

Mark this as Solution if it helps you