Controller code:
public class TestController {
public Boolean uhasAccess {get;set;}
public Boolean isExists {get;set;}
public String selReason {get;set;}
public List<SelectOption> lstReason {get;set;}
public Boolean isReplacement {get;set;}
public TestController () {
BindValues();
}
public List<SelectOption> getlstReason()
{
List<SelectOption> options = new List<SelectOption>();
options.add(new SelectOption('select','----Select----'));
options.add(new SelectOption('H/W - Crash','H/W - Crash'));
options.add(new SelectOption('H/W - Motherboard change','H/W - Motherboard change'));
return options;
}
public void BindValues()
{
isReplacement = false;
isExists = true;
uhasAccess = true;
}
public void SetChangeFlag()
{
if(selReason != 'select')
{
isReplacement = true;
}
else
isReplacement = false;
}
}
I have a checkbox and a dropdownlist. On changing the dropdownlist, the {!isReplacement} flag will be set reRendering the outputpanel rPanel2. But on reRendering, the subPanel Panel3 remains hidden even when {!isExists} is true/checked. it looks like Panel3 is not reRendered