Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

swing disable button


JButton startButton = new JButton("Start");
startButton.addActionListener(new ActionListener() {
     public void actionPerformed(ActionEvent ae) {
        startButton.setEnabled(false);
        stopButton.setEnabled(true);
     }
   }
 );

Source by nullorempty.org #
 
PREVIOUS NEXT
Tagged: #swing #disable #button
ADD COMMENT
Topic
Name
4+1 =