Integer « Text Input « Java Swing Q&A





1. How can I make JFormattedTextField use $1.55, but store the value as the Integer 155?    stackoverflow.com

Almost everything I've ever read about Java says don't use float or double for currency, but it seems like everything in Swing tries to force you to do exactly that if ...

2. JFormattedTextField with 6 integers and 2 decimals    coderanch.com

Hi All, I have a field in which the validation goes something of this sort i.e the user can enter at the max 6 integers and two decimal places. I have tried setting the format by using JFormattedTextField. To some extent i am able to do but when the user enters anything greater than 6 digits it is accepting. It shudn't ...