DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=17391>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=17391

HTML text tag needs to format its content like Bean write

[EMAIL PROTECTED] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WONTFIX



------- Additional Comments From [EMAIL PROTECTED]  2003-02-25 21:45 -------
What you're suggesting won't work.

Even if you force it, it will only lead to problems on form submittal, due to
conversion errors.

For example (I know this works, because I have a running example):
Implementing what you suggest would have the same effect as the following
(except it would only be 1 line):

<bean:define id="myValue">
        <bean:write name="<%=Constants.BEAN_KEY%>" property="integerValue"
format="$###,###"/>
</bean:define>

<html:text property="integerValue" value="<%=myValue%>"/><br>


Now, the page renders fine the first time.  In fact, if myform.getIntegerValue()
has '300' as it's value, then it displays '$300' as expected.  However, when I
submit this page, conversion errors cause the '300' to be lost.
In fact, even this simple work-around doesn't work.....because if we are
returned to this page (for whatever reason) and getIntegerValue returns null,
then an exception is thrown from the define tag.

The only way around this would be to make our field a String, but doing that
means that it won't format correctly, since a Number is required.  Back to
square one.....

Unless someone can find a way to make this work I'm going to mark it as 'Won't Fix'.

In the future, please post these issues to the struts-user list for discussion
first.

Thank you.
James Mitchell

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to