+ Start a Discussion
san5augsan5aug 

How can we refresh a page block which is on page, through a component's actionfunction rerender attribute?

Hi Everybody,

I have a page which is using a component. There is a div tag with id. On component, we have actionfunction with rerender attribute. I am trying to refresh page div on component's rerender attribute.  Please help.

Page:

<apex:page title="CEB - MIR Home Page" sidebar="false" standardcontroller="MIR__c" extensions="MIRHomeController">
<apex:form id="form1">

<div id="addUpcommingActivities" >
                <apex:pageBlock title="Select Activities">
                 <<activity fields>>
                 </apex:pageBlock>
</div>

<apex:pageBlock title="Priorities">
  <c:MIRPriorityDetails p="{!priority}" />
</apex:pageBlock>
</apex:form>
</apex:page>


Component:

<apex:component controller="MIRPriorityDetailController" allowDML="true">
<apex:attribute name="p" type="MIRPriorityDetail" description="Priority" assignTo="{!priority}"/>

<apex:actionFunction name="addMeeting" action="{!addMeeting}" rerender="addUpcommingActivities" >
        <apex:param value="data" name="data" assignTo="{!pid}"/>
    </apex:actionFunction>
</apex:component>
Best Answer chosen by san5aug
Ramu_SFDCRamu_SFDC
Try out the solutions given in the below post(at the end)

https://developer.salesforce.com/forums/ForumsMain?id=906F000000093fcIAA

All Answers

Ramu_SFDCRamu_SFDC
Try out the solutions given in the below post(at the end)

https://developer.salesforce.com/forums/ForumsMain?id=906F000000093fcIAA
This was selected as the best answer
Edwin VijayEdwin Vijay
Can you try putting the DIV around an apex:outputpanel and rerender the outputpanel?
praveen murugesanpraveen murugesan
Hi,

I have faced the similar issue lik that. In my case I was tried to reRender apex:inputText it is not reRendered. So I have used OutPanel and reRendered apex:outputPanel.

And its worked for me. As suggested earlier you can use apex:outputPanel.

Else put id for the pageBlock and reRender the page block.

like this,

                <apex:pageBlock title="Select Activities" id="addUpcommingActivities">
                 <<activity fields>>
                 </apex:pageBlock>

Thanks.

Praveen Murugesan