Try listening for TextInput's valueCommit event.  In you event handler do the 
number formatting.

--- In flexcoders@yahoogroups.com, awesome <cubesp...@...> wrote:
>
> 
> Hi,
> 
> I am banging my head for a couple of hours with this problem and i'm drawing
> a blank. Please anyone for some help on this subject..
> 
> 
> I have a form which is updating mysql table with one of the columns named
> 'price' with data type decimal(5,2).
> 
> In flex i used php service generator to create php for crud db operations.
> Everything works except i cannot enable input with decimal symbol comma
> instead of dot.
> 
> <valueObjects:Products id="products"
> price="{parseFloat(priceTextInput.text)}" />
> <mx:NumberFormatter id="euroPriceInput" precision="2" rounding="none" 
>       decimalSeparatorFrom="," decimalSeparatorTo="."
> useThousandsSeparator="false" />
> <mx:TextInput id="priceTextInput"
> text="{euroPriceInput.format(products.price)}" width="200"/>
> 
> If I type price in format 12.34 it updates correctly but when I use 12,34 it
> saves 12,00. 
> Use of numberformatter does not make a difference. What am I missing? 
> 
> Thank you in advance.
> -- 
> View this message in context: 
> http://www.nabble.com/change-decimal-separator-to-comma-on-input-field-tp25780609p25780609.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
>


Reply via email to