struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From boraldo <bora...@hotbox.ru>
Subject Float conversion: requires comma as floating point symbol.
Date Wed, 01 Apr 2009 18:54:04 GMT

I have a float field on my form. When I type 1.1 (point as floating point
symbol) it shows conversion error
    java.lang.NoSuchMethodException: setPrice([Ljava.lang.String;)
But I do have a method 
    public void setPrice(Float price) {
        this.price = price;
    }
If I type 1,1 (comma as floating point symbol) everything goes well but if
there were errors on the form, on the redisplayed form I see 1.1

Why Struts requires comma for conversion but uses point for displaying ?

-- 
View this message in context: http://www.nabble.com/Float-conversion%3A-requires-comma-as-floating-point-symbol.-tp22833107p22833107.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message