Yes. I agree. From now on I plan to do exac tly that. This program is doing just what you explained. But when I click in the file menu "debit","new account" it is listening
and calls debitnewAccount Or (dbnewacctActionPerformed())
private void dbnewacctActionPerformed(java.awt.event.ActionEvent evt) {
jLabel33.setText(evt.getActionCommand());
if(evt.getActionCommand().equals("New Account")){
pc.setAcctTypeCode("d");//debit
pc.setAcctStatusCode("n");// new
btnSet();
try {
pc.newAccount();
} catch (FileNotFoundException ex) {
ex.printStackTrace();
} catch (IOException ex) {
ex.printStackTrace();
}
acctjLbl.setText("Debit Account: "+String.valueOf(pc.getAccountNo()));
try {
db.setData();
} catch (FileNotFoundException ex) {
ex.printStackTrace();
} catch (IOException ex) {
ex.printStackTrace();
} catch (SQLException ex) {
ex.printStackTrace();
} catch (Exception ex) {
ex.printStackTrace();
}finally{
}
try {
debitTemp();
} catch (FileNotFoundException ex) {
ex.printStackTrace();
} catch (SQLException ex) {
ex.printStackTrace();
} catch (IOException ex) {
ex.printStackTrace();
} catch (Exception ex) {
ex.printStackTrace();
}
}
}
first it sets all the buttons and textboxes with
then
this works fine it creates an new account no
but it need to set new data in
there is a similar metod used for credit card processe in creditcard class called
and these variables should be chaned by db.setData but they don't
then it calls debitTemp()which outputs it to the gui.
[/code]
if i could clidk the menu item debt then new account and have it set data with the DebitCard.java using db.setData(); the rest of the program would work.
I just can't figure the simplest thing "Creating a Debit card .java object that uses the methods of it's parent CreditCard.java but sets the variables relative to debit card.