Update JProgressBar

后端 未结 6 1501
生来不讨喜
生来不讨喜 2021-01-22 21:43

I can\'t update my progressbar... this is my code

Thread t=new Thread(new Runnable(){
        public void run(){
            int i=1;
            jProgBar.setMin         


        
6条回答
  •  借酒劲吻你
    2021-01-22 21:58

    Before the sleep, add a call to SwingUtilties.invokeLater() that spawns a thread to fire a firePropertyChange on the progressbar in the EDT.

提交回复
热议问题