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
KVaishnaKVaishna 

What is use of <apex:inlineEditSupport/> tag?

Hi,

 

I am not sure what is significance of <apex:inlineEditSupport/> because inline editing is enabled using <apex:pageBlock mode="inlineEdit"> so why do we need <apex:inlineEditSupport/>  tag at all..

 

I thought with using <apex:inlineEditSupport /> you can enable inline edit only on certain fields and not on entire block and so you can use dependent picklists and lock certain fields from inline editing within the pageblock.  but that's not the case..!!

 

<apex:inlineEditSupport/> does not work without <apex:pageBlock mode="inlineEdit">..!!

 

Thanks & Regards,

-Kunjan

Jake GmerekJake Gmerek

Look here for full information:

http://www.salesforce.com/us/developer/docs/pages/index_Left.htm#StartTopic=Content/pages_quick_start_inline_editing.htm#kanchor123

 

But in a nutshell it extends the functionality to other apex component types.

 

 

KVaishnaKVaishna

Thanks for the response Jake.

 

Right but if I use pageBlock mode as inlineedit and still get the same thing without even using <apex:inlineEditSupport/>

 

Thanks,

-Kunjan

Jake GmerekJake Gmerek

You can do what you are talking about.  Here is a quick VF page that illustrates what you want:

 

<apex:page standardController="Account">
  <apex:form >
      <apex:pageBlock mode="inlineedit" >
  
          <apex:commandButton action="{!Save}" value="Save"/><br/>
          Account Name: <apex:outputField value="{!Account.name}"/> //This field and all others it the pageblock are editible

      </apex:pageBlock>
      <apex:pageBlock >
          Account Name: 
          <apex:outputField value="{!Account.name}"/> //This field is not editible
          <br/>
          <br/>
          <br/>
          Account Name: 
          <apex:outputField value="{!Account.name}">  //This field is editible
              <apex:inlineEditSupport />
          </apex:outputField>
      </apex:pageBlock>
  </apex:form>
</apex:page>

 

There are other components that work similarly as well that you can play with, although it does say in the documentation that inline edit does not currently work for rich text fields and dependant picklists.  There are also some attributes available to <apex:inlineEditSupport /> that can change the way your page behaves.