This content has been marked as final.
Show 3 replies
-
1. Re: ReRender does not update the Form drop down values
damianharvey Dec 14, 2007 10:24 AM (in response to saeediqbal1)Many potential problems and an equal number of solutions. Post more of your code.
Cheers,
Damian. -
2. Re: ReRender does not update the Form drop down values
saeediqbal1 Dec 14, 2007 11:53 AM (in response to saeediqbal1)Here is the thing, the data in my code comes from my database so i dont think i can have the code out to test. But i can explain as best as possible.
For the list that my action method populates or updates it is defined as follows: -@Out(required=false) private List <String> speedDialCodes;
When i print it in the console it prints out good, but the "reRender" does not render that h:selectOneMenu . I noticed others had problems in this too online.
The solution that i have now is a javascript reloading of the same page but that is no ajax anymore :( I would rather not have the page refresh and let reRender do the updating of my dropdown list but it doesn't.
I even tried this but that didn't help much<a4j:ajaxListener type="org.ajax4jsf.ajax.ForceRender"></a4j:ajaxListener>
If you want you could easily reproduce this code by having a simple list like this in the action method or the constructor and doing .remove() or .add() to it in the action method to see if it gets updated in the viewspeedDialCodes = new ArrayList<String>(); selectedSDCode = "1"; speedDialCodes.add("1"); speedDialCodes.add("2"); speedDialCodes.add("3"); speedDialCodes.add("4"); speedDialCodes.add("5"); speedDialCodes.add("6"); speedDialCodes.add("7"); speedDialCodes.add("8"); speedDialCodes.add("9"); speedDialCodes.add("10");
Any assistance would be appreciated. -
3. Re: ReRender does not update the Form drop down values
pmuir Dec 18, 2007 4:24 PM (in response to saeediqbal1)There is a caching problem with s:selectItems in 2.0.0.GA. Try with a simple f:selectItems.