• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

datatable contents not updating

 
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How come when i change the contents of the array to which the datatable is bound, the datatable does not reflect the change?

I have a checkbox for each row in the datatable. they are bound to a boolean property of an object.. but when i change the values, and run in debug mode, i do see that there values of the array changes. but it just doesn't show in the datatable..why is that?
 
Ranch Hand
Posts: 140
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi there JP,

The moderators are probably going to ask you to change your name, according to the naming policy or something like that.

As to your problem, the short answer is. It should. So perhaps something else is going wrong. Send your code, let's have a look and see if we can help.
 
JP Estrada
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for replying Darryl.. i did some testing, with the table. I bound the same property to an outputText, checkbox and a inputText. The outputText reflected the change, but the checkbox and inputText did not. Have you encountered this problem before?

here's my JSF:

<h:inputHidden id="testText2" value="#{vararrCities.selectedStr}"/>
<h:outputText id="testText" value="#{vararrCities.selectedStr}" rendered="true"/>
<h:selectBooleanCheckbox id="checkbox1"value="#{vararrCities.selectedStr}" />



i updated it this way in my backing bean:

city[0] = new CityBean();
city[0].setCity_id(444);
city[0].setSelectedStr("false");
city[0].setCity_name("TEST CITY");
 
Darryl Nortje
Ranch Hand
Posts: 140
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howzit JP

No problem. Can you try save me a little time, by sending your entire jsp and entire bean. I'm getting busy here at work, so it'll just save me some time in helping you.

cheers
Darryl
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic