Hi Alex,

You may add an extra attribute(displayProperty) in your form bean and have 
it's get(getDisplayProperty) method generate the YES/NO based on the value 
of the checkbox property attribute that you already have and then use this 
new attribute (displayProperty) in your jsp to render YES/NO. Let me know if 
you need any further help.

Thanks,
Amalendu Biswas


>From: "Alex Colic" <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>To: "Struts" <[EMAIL PROTECTED]>
>Subject: setting boolean to yes/no
>Date: Wed, 6 Jun 2001 11:10:44 -0400
>
>Hi,
>
>I have a form with a checkbox that sets a boolean property in one of my
>classes. At a later page I display a msg if the user has selected the
>checkbox and I get 'true' or 'false' displayed. What I am actually looking
>for is a 'Yes' or 'No' to be displayed. Is there a clean way of getting the
>boolean value and then converting it to the 'yes/no' and then displaying
>them on a page?
>
>Thanks for any help.
>
>Alex
><< AlexColic.vcf >>

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com

Reply via email to