Here is the line:
<td width="30"><c:out value="${manageFilerForm.ssnOnFile}" /></td>
The boolean "y":"n" solution looks the cleanest. I am using Tomcat 5.0, and
I tried this:
<td width="30"><c:out value="${manageFilerForm.ssnOnFile?'Y':'N'}" /></td>
but got the following error:
org.apache.jasper.JasperException: <h3>Validation error messages from
TagLibraryValidator for c</h3><p>64: tag = 'out' / attribute = 'value': An
error occurred while parsing custom action attribute "value" with value
"${manageFilerForm.ssnOnFile?'Y':'N'}": Encountered "?", expected one of
["}", ".", ">", "gt", "<", "lt", "==", "eq", "<=", "le", ">=", "ge", "!=",
"ne", "[", "+", "-", "*", "/", "div", "%", "mod", "and", "&&", "or",
"||"]</p>
It may help you to know that I'm using Struts 1.2.4
Hyrum
-----Original Message-----
From: Rick Reumann [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 17, 2005 1:04 PM
To: Struts Users Mailing List
Subject: Re: ActionForm problem
Hyrum wrote the following on 3/17/2005 2:56 PM:
> I have successfully populated a jsp with items from a ValidatorActionForm.
> One of the properties is a boolean, and it is printing the word "true" on
my
> page, where I want a 'Y' or 'N'. So I changed the ValidatorForm so that
the
> property is a string. Now I am getting this error:
>
>
>
> An error occurred while evaluating custom action attribute "value" with
> value "${manageFilerForm.ssnOnFile}": Unable to find a value for
"ssnOnFile"
> in object of class "com.trmarket.tax.forms.ManageFilerForm" using operator
> "." (null)
Could you paste the actual full JSP line that is causing the error?
Also, for what's it worth, if you are using a JSP2.0 container like
Tomcat5, you might want to stick to using boolean for your property and
then you can do:
${manageFilerForm.ssnOnFile?"Y":"N"}
or the old way if not jsp2.0 but using JSTL
<c:choose>
<c:when test='${manageFilerForm.ssnOnFile}'>Y</c:when>
<c:otherwise>N</c:otherwise>
</c:choose>
--
Rick
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]