Can Anyone Help
Dear all,
i made a form that contain some fields and a button and i made a new class for actionlistener ,
this actionlistener calls a method that exists in other class but the actionlistener class don't call the method i want?!
following is the code for the action listener class :
class systemUser_add_user_actionAdapterimplements ActionListener
{
//this is the class that contains the method
databaseAction dbaction;
//this is the class that contains the button
systemUser su;
systemUser_add_user_actionAdapter(systemUser su)
{
this.su = su;
}
publicvoid actionPerformed(ActionEvent ae)
{
dbaction.add_user_actionPerformed(ae);
}
}
thanks in advance for your help
Beginner
>> Huh?
>and what's that supposed to mean?!!!
I suspect it means that your problem/question is not clear because it certainly isn't to me!
I assume that you are expecting method add_user_actionPerformed() on object 'dbaction' to be invoked.
1) Have you added the action listener to the button?
2) Have you tried putting some debug print statements in the actionPerformed() method to make sure it is being invoked?
> >> Huh?
>
> >and what's that supposed to mean?!!!
>
> I suspect it means that your problem/question is not
> clear because it certainly isn't to me!
>
> I assume that you are expecting method
> add_user_actionPerformed() on object 'dbaction' to be
> invoked.
>
> 1) Have you added the action listener to the button?
>
> 2) Have you tried putting some debug print statements
> in the actionPerformed() method to make sure it is
> being invoked?
dear sabre150 ,
First of all thanks for the calrification,
1- of course i have added the action listener to the button
2- after butting debuging statements i determined my problem in the code area i mentioned in my question,
i thought this points are obvious, but any how i hope this carification made something,
thanks again and best regards