/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package progressbar;
/**
*
* @author DEBASISH
*/
import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
import java.awt.event.ActionEvent;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
public class Progressbar {
JProgressBar jprogressbar=new JProgressBar();
JButton jbutton=new JButton("Retrieve information");
public void init(){
Container contentPane=getContentPane();
contentPane.setLayout(new FlowLayout());
contentPane.add(jbutton);
jprogressbar.setForeground(Color.green);
contentPane.add(jprogressbar);
jbutton.addActionListener(new ActionListener(){
public void actionPerformed(ActionEvent e){
jProgressbar.setValue(jprogressbar.getValue()+10);}});
jprogressbar.addChangeListener(new ChangeListener(){
@Override
public void stateChanged(ChangeEvent e){
showStatus("Progressbar minimum::" +jprogressbar.getMinimum() + "maximum:"jProgressbar.getMaximum()+"value:"+jprogressbar.getValue());}
private void showStatus(String string) {
throw new UnsupportedOperationException("Not yet implemented");
}
});
}
private Container getContentPane() {
throw new UnsupportedOperationException("Not yet implemented");
}
}
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
}
private Container getContentPane() {
throw new UnsupportedOperationException("Not yet implemented");
}
}
when i run the program it is showing an error message "Class progressbar.Prgressbar does not have a main method"...... what does it mean ??
plz help..