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!

h:selectOneRadio bean value

843842Jan 16 2007 — edited Jan 16 2007
Hi all,

I have a bean that has a boolean value (called hidestaff) and there is a radio button on my jsp page that must represent this value.

For example, if the boolean is 'true' then the 'yes' radio button should appear as selected.

Here is my code:
<h:selectOneRadio value="#{edit.dataToEdit.hidestaff}" id="choice">
	<f:selectItem id="chno" itemLabel="No" itemValue="No"/>
	<f:selectItem id="chyes" itemLabel="Yes" itemValue="Yes"/>
</h:selectOneRadio>
That code is probably way off, could someone point me in the right direction as to how this is done?

Cheers,

Illu
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 13 2007
Added on Jan 16 2007
1 comment
65 views