Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JButton and ActionListener Question

807607Nov 30 2006 — edited Nov 30 2006
Hey,

I have a 2D array of JButtons and I'm having difficulty getting the ActionListener method to work with it. I can't distinguish between the different components of the JButton array in my actionPerformed method.

Basically, what I'm trying to do is click on one of the JButtons in my 2D array and make it disappear. is there any way I can pass and initialize the index of the clicked JButton array into my actionPerformed method?

Thanks for the help, sorry if it sounds confusing
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 28 2006
Added on Nov 30 2006
10 comments
458 views