Ver Mensaje Individual
  #1 (permalink)  
Antiguo 05/04/2011, 19:52
Avatar de Ronruby
Ronruby
 
Fecha de Ingreso: julio-2008
Ubicación: 18°30'N, 69°59'W
Mensajes: 4.879
Antigüedad: 15 años, 9 meses
Puntos: 416
Formato JFormattedTextField usando DecimalFormat

Estoy tratando de darle el formato ###,###.00 a un campo de texto JFormattedTextField, pero aun dandole ese formato me lo muestra como ###.###,00
Código Javascript:
Ver original
  1. DecimalFormat df = new DecimalFormat("###,###.00");
  2. JFormattedTextField textFieldCantidad = new JFormattedTextField(df);
  3. textFieldCantidad.setColumns(10);
  4. textFieldCantidad.setValue(new Double(20000.00));
¿Que estoy haciendo mal?

He investigado y "deberia" funcionar pero por alguna razon no lo hace como deseo.

Última edición por Ronruby; 05/04/2011 a las 19:57