function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mba75mba75 

Cascading 3 select list

Hi ,
 
 have 3 select list as follow The product family and the product are build with from SOQL query . the rate type make a callout to a external web service .
 
when I select a family it generate the product then when I select the product it call the webservice and generate the Rate type from an XML.
 
But if I change family again it change the product but the rate type stay the same ( It should reinitialise my select list )  :
 
In the following visualforce page I try to use 2 action support in the fist select list
 
 
Any Idea ?  

<apex:pageBlockSection columns="1">

<apex:pageblockSectionItem >

<apex:outputLabel value="Product Family:" for="family"/>

<apex:selectList value="{!family}" size="1" id="Family">

<apex:actionSupport event="onchange" rerender="Products"/>

<apex:actionSupport event="onchange" rerender="Rate_types"/>

<apex:selectOptions value="{!families}"/>

</apex:selectList>

</apex:pageblockSectionItem>

</apex:pageBlockSection>

<br>

<apex:pageBlockSection columns="1">

<apex:pageblockSectionItem >

<apex:outputLabel value="Product:" for="Products"/>

<apex:selectList value="{!Product}" size="1" id="Products" disabled="{!ISNULL(family)}">

<apex:selectOptions value="{!Products}"/>

<apex:actionSupport event="onchange" rerender="Rate_types" />

</apex:selectList>

</apex:pageblockSectionItem>

</apex:pageBlockSection>

<br>

<apex:pageBlockSection columns="1">

<apex:pageblockSectionItem >

<apex:outputLabel value="Rate_type:" for="Rate_types"/>

<apex:selectList value="{!Rate_type}" size="1" id="Rate_types" disabled="{!ISNULL(Product)}">

<apex:selectOptions value="{!Rate_types}"/>

</apex:selectList>

</apex:pageblockSectionItem>

</apex:pageBlockSection>

 

 

 

 

 

 

Ron HessRon Hess
try this form

<apex:actionSupport event="onchange" rerender="Products,Rate_Type"/>


rather than two action support tags, just use one and two rerender targets

mba75mba75
Thank you Ron it is what I need .
 but I apparently also nedd to have the rate type refresh after the Product .
any  
MohanaGopalMohanaGopal
Hi..
    Can u post the Apex class coding .. That is very useful for me....