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

Generating visualforce page based on Edit Page Layout of an Object



I need to create a visual force which is reflected by the Edit Page Layout of an Object.


I am trying to find a solution.Help me to find a solution


Thanks in advance 




Can you be more specific about your req? Do you want a VF Page that would reflect the Edit page layout for an object?


yes, you are correct.VF page need to be generated that would be similar to the edit page layout of an object 


You can use something like this:

You can use tags like dataTable or PageBlockTable that would give you a nice look and feel.


<apex:page standardController="Case" extensions="CaseExtension" >
<apex:sectionHeader title="My Cases" subtitle="Here's How your Page will Look Like"/>
   <apex:form >
      <b>Subject</b> <apex:inputField value="{!cs.Subject}" />


public class CaseExtension{ 

    Case cs;
    public CaseExtension(ApexPages.StandardController controller) 
    public Case getCS()
        return cs;



Thanks for responding, I will try it 

Kamatchi Devi RKamatchi Devi R

Using field sets you can make the field as per the edit page to be reflected in VF pages.

Only the controller used to synchronise the sets field to get reflected there in VF page


Try it out...!

Bhawani SharmaBhawani Sharma
If you want page same like as standard edit page, then why do you want it as VF page. Is there any issue in using the standard page?