Results 1 to 3 of 3
Thread: How to make a JButton disappear?
- 06-04-2008, 01:05 AM #1
Member
- Join Date
- Jun 2008
- Posts
- 1
- Rep Power
- 0
How to make a JButton disappear?
I have a JScrollPane and an arrayList of JButtons. When you click on a JButton, the JButton would disappear(only the click JButton). The class implements ActionListener(with ActionEvent ae. How do I make the JButton disappear. I tried doing JScrollPaneName.remove(ae.getSource())
and
if(ae.getSource() == ArrayListName.get(0))
{
ArrayListName.remove(0);
}
- 06-04-2008, 01:17 AM #2
please show us all your code
My IP address is 127.0.0.1
- 06-04-2008, 02:48 AM #3
Member
- Join Date
- Nov 2007
- Posts
- 1
- Rep Power
- 0
Similar Threads
-
Help with JButton
By geoffreybarwise in forum New To JavaReplies: 4Last Post: 05-21-2008, 10:48 AM -
results to code disappear too fast for DOS window
By dubdubdub in forum New To JavaReplies: 3Last Post: 12-29-2007, 05:07 PM -
Few action in one Jbutton
By kubiasty in forum New To JavaReplies: 0Last Post: 07-25-2007, 10:19 AM -
Problem with JButton
By Marcus in forum AWT / SwingReplies: 1Last Post: 07-05-2007, 05:56 AM -
Mouse over JButton
By sandor in forum AWT / SwingReplies: 1Last Post: 05-17-2007, 09:15 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks