You need to sign in to do that
Don't have an account?
Alignment of VF page on standard page
I am just getting started with VF pages, so please forgive me if this is a basic question.
I have added an Active (checkbox) object to the contact page. If unchecked, I want the Inactive date to be displayed.
I've successfully coded the VF page and added it to my Account page layout. If the contact is active, nothing is displayed. If the contact is not active, the date is displayed.
But the alignment is off. While the fields on the standard contact page have their labels right aligned & the data left aligned, the VF page I've added is left aligned.
Here's a sample:
Contact Owner John Doe
Name Sam Smith
Account Name ABC Industries
Active (unchecked box)
Inactive Date 09/19/2013
(Sorry...I don't know how to post a picture on the board).
Here's the code for the VF page:
<apex:page standardController="Contact">
<apex:form >
<apex:pageblock id="InactiveDtPageBlock" mode="maindetail">
<apex:actionregion >
<apex:pageblocksection columns="1" rendered="{!contact.Active__c == False}">
<apex:outputField value="{!Contact.Inactive_Date__c}"/>
</apex:pageblocksection>
</apex:actionregion>
</apex:pageblock>
</apex:form>
<script>
function setFocusOnLoad(){}
</script>
</apex:page>
Is there a way to align the Inactive Date the same as the other fields?
Thanks,
Connie
We may be having a similar problem:
http://boards.developerforce.com/t5/Visualforce-Development/Aligning-pageBlockTable-section-Columns/td-p/680757