The following gives the right output for num.  So I'm thinking the problem is
somewhere in the converter or I need sleep.

        NumberFormat format = NumberFormat.getInstance(Locale.FRENCH);
        String str = format.format(new BigDecimal(3000));
        Number num = format.parse(str);
        System.out.println("str = " + str);
        System.out.println("num = " + num);



Ned Collyer wrote:
> 
> I have the following
> 
>     private class I18nForm extends Form {
>         public I18nForm(String id) {
>             super(id, new CompoundPropertyModel(new TestModel()));
> 
>             add(new RequiredTextField("bigDecimalProperty"));
>             add(new Button("saveButton"));
>         }
>     }
> 
> This appears to work for japanese, german, english and korean.
> However, if I choose french I get the following behaviour.
> 
> Input: 3000
> Submit
> Output: 3 000
> -----
> Input: 3 000
> Submit
> Output: 3
> 
> 
> Quite annoying - I'm not sure if its actually a bug with NumberFormat in
> core java or specifically the implementation.
> 
> 

-- 
View this message in context: 
http://www.nabble.com/BigDecimal-converter---is-this-behaviour-correct--tp15820747p15820890.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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

Reply via email to