+ Start a Discussion
santosh kottesantosh kotte 

Rendered and Rerendered in vf pages

Can we use rendered and rerendered in same vf page?
Best Answer chosen by santosh kotte
Ankit AroraAnkit Arora
Before this you need to understand what is the difference between both. Rendered is used when you want to display a component on VFP, it's similar to display="none"/display="block" in HTML.

And reRender is bascially used if you want to refresh a part of a VFP. So yes both can be used together.

All Answers

Ankit AroraAnkit Arora
Before this you need to understand what is the difference between both. Rendered is used when you want to display a component on VFP, it's similar to display="none"/display="block" in HTML.

And reRender is bascially used if you want to refresh a part of a VFP. So yes both can be used together.
This was selected as the best answer
Prem_PalPrem_Pal
Render - The particular element is present or not present in the DOM.
It is different than display="none"/display="block", because display attribute just hides/shows an element.
So, if a paricular element render is set to false, we don't see any element in the generated HTML itself.

Rerender - When you want to refresh a particular portion of page. 
You provide an "id", and after some action(e.g. after completion of actionFunction) the element with that "id" is refreshed and it fetches new value from controller.

And as Ankit mentioned, we can use both in same VF page.
santosh kottesantosh kotte
Thanks 4 ur answer