Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JSF Basic Dropdown List - How do I bind inital selection value to property?

843842May 2 2006 — edited May 21 2008
I am working in Java Studio Creator and have a Dropdown list (Basic JSF component) that is tied to a database table.

That works fine, I get the correct items displayed.

The application is to fetch user informatin from a database and have the dropdown list display the current status of the user from the database.

The behavior I am looking for is this:
1) User information is read from database.
2) Property is set to the current user status
3) The dropdown list's selected item changes to the value of the property rather than the first item in the list..

I tried binding the "selected" value of the dropdown list to a "selectedValue"
property and changing it, but that does not seem to work.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 18 2008
Added on May 2 2006
12 comments
1,430 views