src/main/java/com/github/moneytostr/MoneyToStrApp.java
private void setupMoneyToStrVariables() {
        moneyToStrTxt = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.values()[jComboBox3.getSelectedIndex()]);
        moneyToStrNum = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.NUMBER);
        if (jComboBox2.getSelectedIndex() == 3) {
            String[] names = new String[8];
            names[0] = jTextField2.getText();
            names[1] = jTextField3.getText();
            names[2] = jTextField4.getText();
            names[3] = jComboBox7.getModel().getSelectedItem().toString();
            names[4] = jTextField5.getText();
            names[5] = jTextField6.getText();
            names[6] = jTextField7.getText();
            names[7] = jComboBox8.getModel().getSelectedItem().toString();
            moneyToStrTxt = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.values()[jComboBox3.getSelectedIndex()], names);
            moneyToStrNum = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.NUMBER, names);
        }
        boolean isCustomCurrency = jComboBox2.getSelectedIndex() == 3;
        jTextField2.setEnabled(isCustomCurrency);
        jTextField3.setEnabled(isCustomCurrency);
        jTextField4.setEnabled(isCustomCurrency);
        jComboBox7.setEnabled(isCustomCurrency);
        jTextField5.setEnabled(isCustomCurrency);
        jTextField6.setEnabled(isCustomCurrency);
        jTextField7.setEnabled(isCustomCurrency);
        jComboBox8.setEnabled(isCustomCurrency);
    }
private void setupMoneyToStrVariables() {
        moneyToStrTxt = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.values()[jComboBox3.getSelectedIndex()]);
        moneyToStrNum = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.NUMBER);
        if (jComboBox2.getSelectedIndex() == 3) {
            String[] names = new String[8];
            names[0] = jTextField2.getText();
            names[1] = jTextField3.getText();
            names[2] = jTextField4.getText();
            names[3] = jComboBox7.getModel().getSelectedItem().toString();
            names[4] = jTextField5.getText();
            names[5] = jTextField6.getText();
            names[6] = jTextField7.getText();
            names[7] = jComboBox8.getModel().getSelectedItem().toString();
            moneyToStrTxt = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.values()[jComboBox3.getSelectedIndex()], names);
            moneyToStrNum = new MoneyToStr(MoneyToStr.Currency.values()[jComboBox2.getSelectedIndex()],
                MoneyToStr.Language.values()[jComboBox1.getSelectedIndex()],
                MoneyToStr.Pennies.NUMBER, names);
        }
        boolean isCustomCurrency = jComboBox2.getSelectedIndex() == 3;
        jTextField2.setEnabled(isCustomCurrency);
        jTextField3.setEnabled(isCustomCurrency);
        jTextField4.setEnabled(isCustomCurrency);
        jComboBox7.setEnabled(isCustomCurrency);
        jTextField5.setEnabled(isCustomCurrency);
        jTextField6.setEnabled(isCustomCurrency);
        jTextField7.setEnabled(isCustomCurrency);
        jComboBox8.setEnabled(isCustomCurrency);
    }
GEN-LAST:event_jTextField7KeyTyped