Now my query can be modified based on some selectOneMenus. On the valueChangeListener i fire the query to to fetch the data again that populate the columns and rows. However I found that the getter method for the binding Datatable value was called only the first time the datatable is created. Is there some way to force the binding to the datatable again? i have tried different things including moving the pagecode to request scope.
hi, I tried using FacesContext.getCurrentInstance().renderResponse(), but it didn't work. One of my colleagues then suggested obtaining the parent UIComponent and then explicitly removing that specific child. This works.
Originally posted by gov kur: Hi, However I found that the getter method for the binding Datatable value was called only the first time the datatable is created. Is there some way to force the binding to the datatable again? i have tried different things including moving the pagecode to request scope.
Move the lazy loading to the getter of the data list instead of the dataTable.
I have the same problem you encountered, my dynamic columns dataTable is not being reRendered correctly unless i reload the whole page, which is not acceptable. Can you please tell me where you placed this piece of code, in a faces listener ? My dataTable binds to a variable stored in a session scoped bean.
Hi guys, I've encountered the same problem,would you please let me know how did you exactly solve it? I don't understand the solutions you've presented,dear gov kur what is the logic behind the way your colleagues offered?
Is workerTable the element you've bound to your datatable ? And Bauke Scholtz,what do you mean of "Move the lazy loading to the getter of the data list instead of the dataTable."?
Joined: Aug 30, 2004
sorry Andrei ... in my case the whole page gets reloaded. On changing the selectOneMenus, I execute the follwoing code in the valueChangeListener of the selectOneMenus
after this the db query fires and using the fetched data i create the workerTable all over again. All this happens via function calls made in the valueChangeListener function. After this the whole page reloads as I have onchange="submit();" attribute in my selectOneMenu.
yes Nasim, workerTable is the element I've bound to the datatable. It's shown below