How To Use APEX:PAGEBLOCKSECTION In Visualforce Page?

<apex:pageBlockSection>
This tag helps to create a section inside a page block. Multiple sections can be created in a page block and each section can be used to display any fields (input/output).
          A pageBlockSection component consists of one or more columns, By default it's two.each of which spans two cells: one for a field's label, and one for its value. Each component found in the body of an < apex:pageBlockSection > is placed into the next cell in a row until the number of columns is reached. 


This tag supports following attributes:
Attribute Description
collapsible A Boolean value that specifies whether the page block section can be expanded and collapsed by a user. If true, a user can expand and collapse the section. If not specified, this value defaults to true.
columns The number of columns that can be included in a single row of the page block section. Note that a single column spans two cells - one for a field's label, and one for its value. If you use child inputField, outputField, or pageBlockSectionItem components in the pageBlockSection, each of the child components is displayed in one column, spanning both cells. If you use any other components in the pageBlockSection, each of the child components is displayed in one column, displaying only in the rightmost cell of the column and leaving the leftmost column cell blank. While you can specify one or more columns for a pageBlockSection, Salesforce stylesheets are optimized for either one or two columns. If not specified, this value defaults to 2.
dir The direction in which the generated HTML component should be read. Possible values include "RTL" (right to left) or "LTR" (left to right).
id An identifier that allows the pageBlockSection component to be referenced by other components in the page.
lang The base language for the generated HTML output, for example, "en" or "en-US".
onclick The JavaScript invoked if the onclick event occurs--that is, if the user clicks the page block section.
ondblclick The JavaScript invoked if the ondblclick event occurs--that is, if the user clicks the page block section twice.
onkeydown The JavaScript invoked if the onkeydown event occurs--that is, if the user presses a keyboard key.
onkeypress The JavaScript invoked if the onkeypress event occurs--that is, if the user presses or holds down a keyboard key.
onkeyup The JavaScript invoked if the onkeyup event occurs--that is, if the user releases a keyboard key.
onmousedown The JavaScript invoked if the onmousedown event occurs--that is, if the user clicks a mouse button.
onmousemove The JavaScript invoked if the onmousemove event occurs--that is, if the user moves the mouse pointer.
onmouseout The JavaScript invoked if the onmouseout event occurs--that is, if the user moves the mouse pointer away from the page block section.
onmouseover The JavaScript invoked if the onmouseover event occurs--that is, if the user moves the mouse pointer over the page block section.
onmouseup The JavaScript invoked if the onmouseup event occurs--that is, if the user releases the mouse button.
rendered A Boolean value that specifies whether the component is rendered on the page. If not specified, this value defaults to true.
showHeader A Boolean value that specifies whether the page block section title is displayed. If set to true, the header is displayed. If not specified, this value defaults to true.
title The text displayed as the title of the page block section.

You May Also Like: How To Use APEX:COMMANDBUTTON In Visualforce Page?

Example:

<apex:page standardController="Account">
    <apex:form>
        <apex:pageBlock title="Accountt" mode="edit">
              <apex:pageBlockSection title="My Account details" columns="2">
                    <apex:inputField value="{!account.name}"/>
                    <apex:inputField value="{!account.site}"/>
                    <apex:inputField value="{!account.type}"/>
                    <apex:inputField value="{!account.accountNumber}"/>
            </apex:pageBlockSection>
        </apex:pageBlock>
    </apex:form>
</apex:page>
The above code generated the below page:

VF_pageBlockSection

COMMENTS

Name

Apex Apex Default Methods Apex Methods Apex_Collections Apps Batch Apex Books CRM eBooks Data Import Wizard Data Management DataLoader Dataloader.io Difference Between Error in Salesforce FAQ's FAQ's-Apex FAQ's-Apps FAQ's-CRM FAQ's-Data loader FAQ's-SOQL & SOSL FAQ'S-Triggers FAQ's-User Profile & Security FAQ's-VF Force.com Explorer Force.com Ide Formulas & Functions Integration Interview Questions Only Latest_Updates Limits&Best Practices Online-Training Reports and Dashboards Salesforce Deployment Salesforce Realtime Examples On Development Salesforce Realtime Task On Admin Salesforce Realtime Tasks Salesforce Realtime Tasks- Apex Salesforce Training Salesforce1 Mobile Sites SOQL Spring'14 Release Triggers User Profile & Security VF Tags VisualForce Winter'14 Release Wizard for Accounts/Contacts Workbench Workflows and Approvals
false
ltr
item
Sfdc Gurukul- All in one place for salesforce and force.com step by step tutorial for beginners: How To Use APEX:PAGEBLOCKSECTION In Visualforce Page?
How To Use APEX:PAGEBLOCKSECTION In Visualforce Page?
How To Use APEX:PAGEBLOCKSECTION In Visualforce Page?,apex:pageBlockSection,,pageBlockSection in salesforce,pageBlockSection in visualforce,visualforce pageBlockSection tag
http://4.bp.blogspot.com/-3PhvvR15NNg/Ud0ZP6qry1I/AAAAAAAAAUI/N-v1eO1dysA/s640/VF_pageBlockSection.JPG
http://4.bp.blogspot.com/-3PhvvR15NNg/Ud0ZP6qry1I/AAAAAAAAAUI/N-v1eO1dysA/s72-c/VF_pageBlockSection.JPG
Sfdc Gurukul- All in one place for salesforce and force.com step by step tutorial for beginners
http://sfdcgurukul.blogspot.in/2013/07/how-to-use-apexpageblocksection-in.html
http://sfdcgurukul.blogspot.in/
http://sfdcgurukul.blogspot.com/
http://sfdcgurukul.blogspot.com/2013/07/how-to-use-apexpageblocksection-in.html
true
4199533888133360731
UTF-8
Not found any posts VIEW ALL Readmore Reply Cancel reply Delete By Home PAGES POSTS View All RECOMMENDED FOR YOU LABEL ARCHIVE SEARCH ALL POSTS Not found any post match with your request Back Home Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sun Mon Tue Wed Thu Fri Sat January February March April May June July August September October November December Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec just now 1 minute ago $$1$$ minutes ago 1 hour ago $$1$$ hours ago Yesterday $$1$$ days ago $$1$$ weeks ago more than 5 weeks ago Followers Follow THIS CONTENT IS PREMIUM Please share to unlock Copy All Code Select All Code All codes were copied to your clipboard Can not copy the codes / texts, please press [CTRL]+[C] (or CMD+C with Mac) to copy