0

Can we have a pagelayout of an object embedded into a Vf page? I have a Vf page which has captures some information, i also want to be able to create a new event in the same page.

I could have all the event fields in the Vfpage and create the event. Is there a simpler way of doing it like embedding the events page layout into the VF page.

Thanks

2 Answers 2

5

I believe you can just use the apex:detail tag. See http://www.salesforce.com/us/developer/docs/pages/Content/pages_compref_detail.htm

apex:detail uses the default page layout for the profile of the user viewing the page as well as the record type of the record being viewed.

<apex:page standardController="Account">
  <apex:detail/>
  Put the rest of your page content here...
</apex:page>
1

You can use an apex:iframe to embed content into a visualforce page

eg :

<apex:page standardController="Account">
<apex:outputText value="The Account Is  "/>
  <apex:iframe src="/{!Account.Id}"   />
</apex:page>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.