Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Referencing jsf list properties from backing beans

Status
Not open for further replies.

sapatos

Programmer
Jan 20, 2006
57
AU
Hi,

I've bound a list to a database table. I have a jsf table bound to the same table and want to update the display of the data in the table depending on the option chosen in the list. I've found a cracking tutorial to help with this but in the session bean I've tried the following code:

public void personIdDD_processValueChange(ValueChangeEvent event) {
try {
getSessionBean1().getTripRowSet().setObject(
1, personIdDD.getSelected()); // <--Problem here
tripDataProvider.refresh();
} catch (Exception e) {
error("Cannot switch to person " +
personDataProvider.getValue(
"PERSON.PERSONID"));
log("Cannot switch to person " +
personDataProvider.getValue(
"PERSON.PERSONID"), e);
}
}

this method is trying to reference the personIdDD UIComponent directly. It is not bound to a field in the session bean (which would allow the reference to work) instead it is trying to reference the id directly from the jsp page. I'm not sure how to work around this, maybe I'm missing something obvious. The full tutorial for this is at


Any ideas?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top