i am running a program that execute quite a numbers of loop. the program will not be responsive when running with those loop. i want to create a form that stay on top of the program and notify the user about the progress of execution.
How can i do that? i try to google the example but no luck. and the clue point me to use threading which i am not really good at (know a bit).
can anyone show me a very simple coding regarding to this problem? just a simple waiting form stay on the main form when the main program is executing a huge loop. after loop finish, the waiting screen gone.
Thanks your all help in advanced!
John Jai
Bartender
Joined: May 31, 2011
Posts: 1776
posted
0
If the UI is Swing then you can use the wait cursor.
jamil lusa
Ranch Hand
Joined: Aug 18, 2011
Posts: 58
posted
0
i need a form-like waiting screen instead of waiting cursor because it can provide more information (display on the waiting form) for the user.
Tim Moores
Rancher
Joined: Sep 21, 2011
Posts: 2407
posted
0
What prevents you from putting a dialog in front of the main window whenever you need to?
Campbell Ritchie
Sheriff
Joined: Oct 13, 2005
Posts: 32651
4
posted
0
I think this thread would sit better on our GUIs forum, so shall move it.
Please avoid coloured text; some people find it very difficult to read.
hi all, but i am still curious how to create a customized loading form (something like showing 'please wait...') by myself using threading because it is a good chance to learn that.
anyone is kind enough to show me? thanks.
Michael Dunn
Ranch Hand
Joined: Jun 09, 2003
Posts: 4632
posted
1
here's a quick (rough) example
click the button, the dialog will show, you can move the dialog, but not close it or access the frame
when the task is over, the dialog disappears, and you can again access the frame
(this is not a good example of doing what you want, ProgressMonitor is the better/best way)