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
Sumsum2253Sumsum2253 

Account Page layout Development - Help please?

Hi All,

 

I am developing a solution that will enable our client services team to gather extensive info (data) on our existing customers at both Accoutn & Contact level.

 

There is a requirement to be able to display this information in a certain way on the detail page layout...

 

So my question is - Is it possible to have a section in the detail page with more than 2 columns?

 

the most i would need is to be able to display 4 fiels side by side rather than just 2?

 

Is this possible?

 

i only have very basic apex knowledge at the moment so if it requires programming would it be something i could do myself?

 

many thanks in advance for any help with this?

 

Ian

Ankit AroraAnkit Arora

On native screen you can't do this. But using visualforce yes you can, so here is the code which will help you to understand what you need to do :

 

<apex:page standardController="Account">
   
    <apex:sectionHeader title="{!$ObjectType.Account.label}" subtitle="{!Account.name}"/>
      <apex:form >
      <apex:pageBlock>
        <apex:pageBlockSection columns="4">
            <apex:outputLabel value="My Field 1"/>
            <apex:outputLabel value="My Field 2"/>
            <apex:outputLabel value="My Field 3"/>
            <apex:outputLabel value="My Field 4"/>
            <apex:outputLabel value="My Field 5"/>
            <apex:outputLabel value="My Field 6"/>
            <apex:outputLabel value="My Field 7"/>
            <apex:outputLabel value="My Field 8"/>
        </apex:pageBlockSection>
     </apex:pageBlock>
  </apex:form>
</apex:page>

 So "<apex:pageBlockSection columns="4">" is playing the most inportant part, which will display 4 fields in a row.

 

 

Thanks
Ankit Arora
Sumsum2253Sumsum2253

Hi Ankit,

 

Thanks for this.

 

This gives the section the characteristics of a "related list" section. I see the basic structure is there only I need the fields to be input free text fields to allow the Users to input data.

 

Do I need to change the ($ObjectType) of the "<apex:sectionHeader>" attribute to make it mirror the other sections in the detail page... I've had a play with this but can't seem to figure it out?

 

I can change the "<apex:outputLabel>" to "<apex:inputField>" and then insert the custom field name to the "Value" attribute...

 

For example - "<apex:inputField value="{!account.Strengths__c}"/>" -

 

But this does not make the field display the way it should... Is there another attribute I need to add to this tag to make the field display correctly on the page?

 

Thanks again for your help

 

Ian.