+ Start a Discussion
ForceComForceCom 

Rendering a field !!!!

Hi , 

 

I want a render a field based on if the user clicks on a link or not. The same way how we can render a field based on the check box.

 

Any insights.....appreciated...

 

Thanks

bob_buzzardbob_buzzard

Can you clarify a little - what is the user experience - is it that they click on a link and stay on the same page but some additional markup appears?

 

One way to do this would be to have a commandlink with a rerender.  The command link calls an action method on the controller which sets a flag or similar to indicate the additional content should be rendered.  

 

One thing to beware of - you can't render something that wasn't there in the first place, so you have to wrap it in another container as described at:

 

http://bobbuzzard.blogspot.co.uk/2011/02/visualforce-re-rendering-woes.html