Created
September 27, 2014 07:33
-
-
Save keirbowden/0150a1e37b181323a0bb to your computer and use it in GitHub Desktop.
Action Region, Required Field and HTML5 Page
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<apex:page controller="RequiredCtrl" tabstyle="Account" doctype="html-5.0"> | |
<apex:pageMessages id="msgs"/> | |
<apex:form> | |
<apex:pageBlock mode="maindetail"> | |
<apex:pageBlockButtons location="top"> | |
<apex:commandButton value="Save" action="{!save}" /> | |
</apex:pageBlockButtons> | |
<apex:pageBlockSection title="Account Information"> | |
<apex:pageBlockSectionItem> | |
<apex:outputlabel value="Name"/> | |
<apex:inputfield value="{!Acc.Name}"/> | |
</apex:pageBlockSectionItem> | |
</apex:pageBlockSection> | |
<apex:outputPanel id="rows"> | |
<apex:actionRegion> | |
<apex:pageBlockSection title="Related Information" columns="1"> | |
<apex:pageBlockSectionItem> | |
<apex:commandButton value="Add Row" action="{!addRow}" rerender="rows,msgs"/> | |
</apex:pageBlockSectionItem> | |
<apex:pageBlockTable value="{!rows}" var="row"> | |
<apex:column headerValue="Value 1"> | |
<apex:inputText value="{!row.val1}" /> | |
</apex:column> | |
<apex:column headerValue="Value 2"> | |
<apex:inputText value="{!row.val1}" /> | |
</apex:column> | |
<apex:column headerValue="Value 3"> | |
<apex:inputText value="{!row.val3}" /> | |
</apex:column> | |
</apex:pageBlockTable> | |
</apex:pageBlockSection> | |
</apex:actionRegion> | |
</apex:outputPanel> | |
</apex:pageBlock> | |
</apex:form> | |
</apex:page> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment