hi all,i have a problem with h:selectoneradio valuechangelistener and ajax.
---jsf--
<h:selectOneRadio valueChangeListener="#{gradeBean.checkSettingSelection}" value="#{gradeBean.settingSelection}">
<f:selectItem itemLabel="Automate" itemValue="1"/>
<f:selectItem itemLabel="Manual" itemValue="2" />
<a4j:support reRender="auto,manual" event="onclick"/>
</h:selectOneRadio>
<a4j:outputPanel id="auto" rendered="#{gradeBean.autoCheck}">
<h:inputText value="gradeBean.value"/>
</a4j:outputPanel>
<a4j:outputPanel id="manual" rendered="#{gradeBean.manualCheck}">
<h:inputText value="gradeBean.value1"/>
</a4j:outputPanel>
--backingbean-
public void checkSettingSelection(ValueChangeEvent vce){
String check = (String)vce.getNewValue();
if(check.equalsIgnoreCase("1")){
this.setAutoCheck(true);
this.setManualCheck(false);
}
if(check.equalsIgnoreCase("2")){
this.setManualCheck(true);
this.setAutoCheck(false);
}
}
what im trying to do here is .. there is 2 radiobutton and when a user select option 1, option 1 with all the fields will appear while option 2 will not appear. vice versa.
my problem is im tryin to use a4j support so that only portion of the page is rerender and not the whole page to reload. however it is not working. anyone can help me?
thanks
alot!