I want to show some text when I click on the button partially updating page.
Why reRender option doesn't work? Here is my code
controller:
public class CustomAccountController {
public Boolean contactCreation {get; set;}
public CustomAccountController() {
contactCreation = false;
}
public PageReference show() {
contactCreation = true;
return null;
}
}
VF Page :
<apex:page controller="CustomAccountController">
<apex:form >
<apex:commandButton value="New" reRender="viewNew" action="{!show}"/>
<apex:outputPanel id="viewNew" rendered="{!contactCreation}">
<apex:outputText value="Hello"/>
</apex:outputPanel>
</apex:form>
</apex:page>