You need to sign in to do that
Don't have an account?
Rerender rerender part of page but then whole page is refeshed
<apex:page standardController="Account" recordSetvar="accounts"
extensions="Account2MapControllerExt">
<script src="http://maps.google.com/maps?file=api&v=2.x&key={!mapkey}" type="text/javascript"></script>
<script src="http://www.google.com/jsapi?key={!mapkey}" type="text/javascript" ></script>
<apex:form >
<apex:pageBlock >
<apex:pageBlockSection title="Select Account List" columns="1" collapsible="false">
<apex:outputPanel > Select an account list view to map :
<apex:selectList value="{!filterId}" size="1">
<apex:selectOptions value="{!listviewoptions}" />
</apex:selectList>
<apex:commandButton value="Go!" >
<apex:actionSupport event="onclick" reRender="accTable" status="accStatus" />
</apex:commandButton>
<apex:actionStatus id="accStatus" startText="(incrementing...)" stopText="(done)"/>
</apex:outputPanel>
</apex:pageBlockSection>
<apex:pageBlockSection >
<apex:dataTable value="{!accounts}" var="a" id="accTable" rows="3">
<apex:column value="{!a.id}" rendered="false"/>
<apex:column value="{!a.name}" rendered="true"/>
</apex:dataTable>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
Message Edited by PerGeert on 11-22-2008 06:19 PM
Message Edited by PerGeert on 11-22-2008 07:50 PM
I think you'll find that the 'actionSupport' tag is rerendering the list, then the commandButton is refreshing the page (both asking for the same data), so if you move the rerender and status bits from the actionSupport tag into the commandButton tag, then remove the actionSupport tag, it should work ok.