This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Struts and the fly likes selectOneMenu and value in the backing Bean  in JSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "selectOneMenu and value in the backing Bean  in JSF" Watch "selectOneMenu and value in the backing Bean  in JSF" New topic
Author

selectOneMenu and value in the backing Bean in JSF

Mary White
Ranch Hand

Joined: Jan 27, 2003
Posts: 41
Hi,
I have the following code in my JSP:


and in my backing bean


but the roleID property allways have the default value: the String "null" in this case.

The only way that I have been able to change its value is through the valueChange listener in the jsp:

Is there any way to set the value of the property without the listener?
[ November 03, 2004: Message edited by: Mary White ]
Bruno Collet
Ranch Hand

Joined: Jun 08, 2004
Posts: 40
Its a binding value. You have to write #{admin.roleId}.


Bruno Collet<br /><a href="http://www.practicalsoftwarearchitect.com" target="_blank" rel="nofollow">www.practicalsoftwarearchitect.com</a><br />- The Paradox of Software Architecture: It is easy to make a complex architecture, but it is difficult to make a simple architecture.
Mary White
Ranch Hand

Joined: Jan 27, 2003
Posts: 41
Hi Bruno!
Thanks for looking into my problem.
A second set of eyes is always helpful.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: selectOneMenu and value in the backing Bean in JSF
 
Similar Threads
MyFaces - HtmlSelectOneMenu and ValueChangeEvent
Facing Problem in JSF form SelectItem[]
Populating data in h:selectOneMenu from Database
on change combo box not working.
Validation Error on SelectOneMenu