What's the best practice for using Formatters and Bindings together?
 
For example:
- I have a currency value that's stored as a number in my model (And in the database)
- I retrieve the value and use the CurrencyFormatter to make it look like $15,123 which is displayed in a TextInput component.
- So far, so good. But, now my user edits the value and wants to save it back to the database
- But, the new value in the TextInput component isn't a number anymore!
 
Do I:
- Have to write an unformatter for each formatter?
- Create a custom CurrencyTextInput component that has both a formatted and unformatted version of the data
- Am I looking at this all wrong and need to think differently?
 
It seems like this situation must come up all the time, and I expect an easier way to make it work. All the examples in the docs show formatting with two fields -- One formatted and one not formatted. But, I don't think users want to see it this way.
 
Thanks much for any advice!
 
   Clarke
__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Software development tool Software development Software development services
Home design software Software development company


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to