+ Start a Discussion
Sindhu AmbarkarSindhu Ambarkar 

The inline edit-enabled dependent picklist 'picklist subcategories' requires its controlling field 'Industry' to be present on the page

Hi,

Iam getting this error in visualforce page while compiling this program.

<apex:page standardController="Account">
<apex:form>
<!-- Don't mix a standard input field... -->
<apex:inputField value="{!account.industry}"/> //controlling field
<apex:outputField value="{!account.picklist_subcategories__c}"> //dependent 
<!-- ...with an inline-edit enabled dependent field -->
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField>
</apex:form>
</apex:page>
Can anyone explain this
ankur manochaankur manocha
Hi Sindhu,

This is working as designed, you cannot mix a inline edit-enabled fields with regular input fields from the same dependency group. For example, don’t mix a standard input field for a controlling field with an inline edit-enabled dependent field i.e in your case controlling field is "industry" which is a standard field.

As a workaround, you may use <apex:outputPanel></apex:outputPanel>, As refreshing fields individually isn’t recommended and might result in inconsistent undo/redo behavior.

Please mark this answer as best answer if this helps.

Regards,
Ankur
ankur manochaankur manocha
Help URL: https://help.salesforce.com/apex/HTViewSolution?id=000199154&language=en_US (https://help.salesforce.com/apex/HTViewSolution?id=000199154&language=en_US)
 
Sindhu AmbarkarSindhu Ambarkar
Hi Ankur,

I didnt understand why am getting the error in the above example.Can you please elaborate it
KaranrajKaranraj
Sindhu - You have to use the inline edit support for the both controlling and dependent field as well. In your code, the controlling field are disaplyed as inputfield, you have to change that into output field and set the inline edit support for the controlling field also. Try the below code for the sample
<apex:page standardController="Account">
<apex:form >
<!-- Don't mix a standard input field... -->
<apex:outputField value="{!account.industry}">
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField> //controlling field
<apex:outputField value="{!account.Subcategories__c}"> //dependent 
<!-- ...with an inline-edit enabled dependent field -->
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField>
</apex:form>
</apex:page>

Thanks,
Karanraj (http://www.karanrajs.com)
 
Sindhu AmbarkarSindhu Ambarkar
Iam getting the error  while compiling code
KaranrajKaranraj
What error message you are getting? Make sure that you have mentioned correct API name of the field in the visualforce page.
<apex:page standardController="Account">
<apex:form >
<!-- Don't mix a standard input field... -->
<apex:outputField value="{!account.industry}">
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField> //controlling field
<apex:outputField value="{!account.picklist_subcategories__c}"> //dependent 
<!-- ...with an inline-edit enabled dependent field -->
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField>
</apex:form>
</apex:page>
Sindhu AmbarkarSindhu Ambarkar
Iam getting this after executing

Agriculture//controlling fieldapple farms //dependent
i didnot understand the purpose of inlineeditsupport
Sindhu AmbarkarSindhu Ambarkar
Thanks a lot
Sudha Madhuri MarripatiSudha Madhuri Marripati
<apex:page standardController="Account">
<apex:form >
<apex:pageBlock >
<apex:pageblockSection >
<apex:outputField value="{!account.Industry}">
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField> 

<apex:outputField value="{!account.Subcategories__c}">
<apex:inlineEditSupport event="ondblClick" />
</apex:outputField> 
</apex:pageblockSection>
</apex:pageBlock>
</apex:form>
</apex:page>