Timer or other idea required to allow code to continue execution after calling method and JOptionPane

后端 未结 3 1448
[愿得一人]
[愿得一人] 2020-12-04 02:58

I need a way to allow my program to keep running code after this method is called.

Currently, it waits for half an hour, gets the info, stores it to the object WeatherCar

3条回答
  •  再見小時候
    2020-12-04 03:29

    JOptionPane is modal, which means code execution blocks until the user dismisses or acknowledges it. You need to use a non-modal dialog. Consider creating your own JDialog. http://docs.oracle.com/javase/tutorial/uiswing/components/dialog.html

提交回复
热议问题