private void createNew(){
  log.config("");
  String value=valueField.getText();
  if (value.length() == 0) {
    valueField.setBackground(AdempierePLAF.getFieldBackground_Error());
    return;
  }
  String name=nameField.getText();
  if (name.length() == 0) {
    nameField.setBackground(AdempierePLAF.getFieldBackground_Error());
    return;
  }
  int C_ElementValue_ID=createElementValue(value,name,isExpense.isSelected());
  if (C_ElementValue_ID == 0) {
    ADialog.error(m_WindowNo,panel,"ChargeNotCreated",name);
    return;
  }
  int C_Charge_ID=createCharge(name,C_ElementValue_ID);
  if (C_Charge_ID == 0) {
    ADialog.error(m_WindowNo,panel,"ChargeNotCreated",name);
    return;
  }
  ADialog.info(m_WindowNo,panel,"ChargeCreated",name);
}

private void createNew ( ) { log . config ( "" ) ; String value = valueField . getText ( ) ; if ( value . length ( ) == 0 ) { valueField . setBackground ( AdempierePLAF . getFieldBackground_Error ( ) ) ; return ; } String name = nameField . getText ( ) ; if ( name . length ( ) == 0 ) { nameField . setBackground ( AdempierePLAF . getFieldBackground_Error ( ) ) ; return ; } int C_ElementValue_ID = createElementValue ( value , name , isExpense . isSelected ( ) ) ; if ( C_ElementValue_ID == 0 ) { ADialog . error ( m_WindowNo , panel , "ChargeNotCreated" , name ) ; return ; } int C_Charge_ID = createCharge ( name , C_ElementValue_ID ) ; if ( C_Charge_ID == 0 ) { ADialog . error ( m_WindowNo , panel , "ChargeNotCreated" , name ) ; return ; } ADialog . info ( m_WindowNo , panel , "ChargeCreated" , name ) ; }
create new account and charge
