albertlee Posted October 17, 2005 Posted October 17, 2005 package supershare; import java.awt.event.*; import javax.swing.*; public class testGUI extends javax.swing.JFrame implements java.awt.event.ActionListener{ public testGUI(){initComponents();} public void initComponents(){/*Generated Code*/} public static void main(String args[]) { new testGUI().setVisible(true); } public void actionPerformed(ActionEvent e) { /*JProgressBar jp = new JProgressBar(0' date=' 100); jp.setValue(0); jp.setStringPainted(true); this.add(jp); this.validate();*/ this.remove(jButton1); this.validate(); this.repaint(); } // Variables declaration - do not modify private javax.swing.JButton jButton1; // End of variables declaration } [/quote'] Above is the code I made under NetBeans.... As you know, NetBeans has a function called "JFrameForm", which allows you to design GUI more conviniently.... if you are familar with NetBeans, you can easily understand the above code... You know what I am trying to do is that when I click the button, the button should disappear, but it doesnot.... please help here... actually, I have a bigger project meeting this problem.. and if I have to design the whole project without using NetBeans's JFrameForm function, it will be a nightmare...yes, lots of work... Apreciate any help thanks
albertlee Posted October 18, 2005 Author Posted October 18, 2005 Has any one used NetBeans before?? Is my question that hard????
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now