Thread: problem in java
View Single Post
Old 03-17-2003, 09:53 PM   PM User | #7
Spookster
Supreme Overlord


 
Spookster's Avatar
 
Join Date: May 2002
Location: Marion, IA USA
Posts: 6,225
Thanks: 4
Thanked 80 Times in 79 Posts
Spookster will become famous soon enough
Or in your case since you have a button you could define it like so:

PHP Code:
public void actionPerformed(ActionEvent event){
        if(
event.getSource() instanceof Button){
            
Button clickedButton = (Buttonevent.getSource();
            if(
clickedButton == goButton){
                
//Action to perform when go button clicked
            
}
         }

__________________
Spookster
CodingForums Supreme Overlord
All Hail Spookster
Who gave you that Ugging infraction? Yeah that's right it was me!
Spookster is offline   Reply With Quote