My problem (lines in bold) is that the buttons that I add the ActionListener to are not in the same class as actionPerformed. When I tried to make the JButtons public (outside of the current class), it gave me some exceptions. What can I do to properly add this ActionListener? [ October 31, 2008: Message edited by: Thomas FairBanks ]
The best solution for this problem is to use a different ActionListener per Button - then there is no need to call e.getSource at all.
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus