problem on progress bar
I am doing the swing application in netbeansIDE.In that i select javadesktop application.In my project i take progressbar to show the progress of my application.when the application is start running i start the progresbar as
hear the progress bar is starting with max value 0
and i run some methods like
when executing the methods the progress bar is not incremented.according to running my application i want to increase my progress bar.But not manually incremented.
Read the API for JProgressBar and follow the link to the tutorial on "How to Monitor Pregress" where you will find working examples. If you still have a problem, post a SSCCE* and ask a specific question.
* SSCCE : Java Glossary
I can't say that progress won't show if the progress bar is updated by a process running on the EDT, but progress bars were made to be updated by a process running in another thread. Note that the progress updates have to be made using EventQueue.InvokeLater() so they happen on the EDT, but doing so gives the EDT time to redraw the screen. Possibly, you are updating the progress bar, but the fact that the main process is blocking the EDT is preventing the updates from appearing. Also, max value = 0 doesn't sound like a good idea...