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
GobbledigookGobbledigook 

Strange display after overriding VF edit page.

Hey all,

 

I'm getting a strange display on a standard view page, after overriding the standard edit page using Visualforce.  The thing is, with the Visualforce page, I'm not really doing much of anything, other than recreating the page (using the standard input fields) and adding a button. 

 

I'll just post the Code itself: As you can see I'm not really doing much with it, just redisplaying the view itself, adding in the "save and add call attendees" button.  The extension itself does nothing with the problem I'm experiencing.

 

 

<apex:page standardController="Call_Report__c" extensions="FD_CallReportSave" action="{!Redirect}" tabStyle="Call_Report__c" showHeader="true" sidebar="true">
    <apex:SectionHeader title="{!$ObjectType.Call_Report__c.label} Edit" subtitle="New Call Report"/>
    <apex:form id="theForm">
        <apex:pageBlock title="{!$ObjectType.Call_Report__c.label} Edit" mode="edit" id="thePageBlock">
            <apex:pageBlockButtons >
                <Apex:commandbutton value="Save and Add Call Attendee" Action="{!SaveAdd}" />
                <apex:commandButton value="Cancel" Action="{!cancel}" immediate="true"/>
            </apex:pageBlockButtons>
            <apex:pageBlockSection title="{!$ObjectType.Call_Report__c.label} Information" columns="1">
                <!--Row 1-->
                <apex:inputField value="{!Call_Report__c.Account__c}"/>
                <!--Row 2-->
                <apex:inputField value="{!Call_Report__c.Date__c}" required="true"/>
                <!--Row 3-->
                <apex:inputField value="{!Call_Report__c.Type_of_Interaction__c}" required="true"/>
                <!--Row 4-->
                <apex:inputField value="{!Call_Report__c.Products_Discussed__c}"/>
                <!--Row 5-->
                <apex:inputField value="{!Call_Report__c.Project__c}"/>
                <!--Row 6-->
                <apex:inputField value="{!Call_Report__c.Other_Project__c}"/>
            </apex:pageBlockSection>
            <apex:pageBlockSection title="Call Comments" columns="1">
                <!--Row 1-->
                <apex:inputField value="{!Call_Report__c.Summary__c}" required="true" style="Width:400px;"/>
                <!--Row 2-->
                <apex:inputField value="{!Call_Report__c.Comments__c}" style="Width:400px;"/>
            </apex:pageBlockSection>   
            <apex:pageBlockSection title="Additional Details" columns="2">
                <!--Row 1-->
                <apex:inputField value="{!Call_Report__c.Missed_Opportunity__c}" required="true" />
                <apex:inputField value="{!Call_Report__c.ERP_Document_Num__c}" id="ERPDocNum"/>
                <!--Row 2-->
                <apex:inputField value="{!Call_Report__c.Missed_Opportunity_Products__c}" />
                <apex:inputField value="{!Call_Report__c.ERP_Document_Type__c}" />
                <!--Row 3-->
                <apex:inputField value="{!Call_Report__c.M_O_Reason__c}" />
                <apex:inputField value="{!Call_Report__c.M_O_Other_Reason__c}" />
            </apex:pageBlockSection>
            <!--<apex:pageBlockSection title="Additional Information" > 
                <apex:inputField value="{!Call_Report__c.Attendee_Summary__c}" style="width:400px;" rendered="false"/>   
            </apex:pageBlockSection>   -->
            <apex:pageBlockSection title="Call Report Email Notifications" columns="2">
                <!--Row 1-->
                <apex:inputField value="{!Call_Report__c.Applications_Engineer__c}" />
                <apex:inputField value="{!Call_Report__c.U_S__c}" />
                <!--Row 2-->
                <apex:inputField value="{!Call_Report__c.Global__c}" />
                <apex:inputField value="{!Call_Report__c.U_K__c}" />
            </apex:pageBlockSection>
        </apex:pageBlock>
    </apex:form>
</apex:page>

 

Now I should say a few things: Missed_Opportunity_Products__c and M_O_Reason__c are dependent picklists of the Missed_Opportunity__c Picklist.  This is where I'm getting the strange error. 

 

If Missed_Opportunity is Yes, the other picklists are filled and everything displays ok:

 

But when Missed Opportunity is no:

 

I get the strange display.  Can anyone shed some light on it?  It's not a crippling feature it's just kind of annoying.