I am working on VF page – when I change the value of a picklist field then my pageblock table will show.
VF code
<apex:page sidebar="false" controller="AllObjectCtrl">
<apex:form>
<apex:pageBlock title="All Objects in Org">
<apex:pageBlockSection>
<apex:selectList value="{!objectName}" size="1">
<apex:selectOptions value="{!Name}">
<apex:actionSupport event="onChange" action="{!getrecords}" reRender="tableShow"/>
</apex:selectOptions>
</apex:selectList>
<apex:pageBlockTable value="{!selectedObj}" var="a" id="tableShow">
<apex:column value="{!a}" headerValue="ID"/>
</apex:pageBlockTable>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
Best Answer
you are using this thats why it is not running
because the even="OnChange"is a java script finction and as java script is a case sensetive language so rather then using Capital c on onChnage use small "c" in onchange like this :