Permalink
Browse files

Fixed npe

  • Loading branch information...
1 parent 1c3bc50 commit eea96258ab64259510bf10247a587b1c1dc3407e @anti43 committed Mar 24, 2013
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/mpv5/ui/dialogs/subcomponents/ControlPanel_Taxes.java
View
3 src/mpv5/ui/dialogs/subcomponents/ControlPanel_Taxes.java
@@ -35,6 +35,7 @@
import mpv5.ui.dialogs.Popup;
import mpv5.ui.panels.DataPanel;
import mpv5.usermanagement.MPSecurityManager;
+import mpv5.utils.numberformat.FormatNumber;
import mpv5.utils.ui.TextFieldUtils;
/**
@@ -260,7 +261,7 @@ public Component getAndRemoveActionPanel() {
public boolean collectData() {
try {
cname_ = cname.getText();
- taxvalue_ = new BigDecimal(value.getValue(0d).toString());
+ taxvalue_ = FormatNumber.parseDezimal(value.getText(true, "0"));
country_ = countries.getComboBox().getSelectedItem().toString();
return true;
} catch (Exception e) {

0 comments on commit eea9625

Please sign in to comment.