Hello, i'm trying to do some work in a thread while showing a progress dialog until the work is done in the most simple possible way, so far i got this:
// "this" is the current activity final ProgressDialog prgDialog = ProgressDialog.show(this, "", "Working...", true, false); new Thread() { public void run() { Util.DoSomeWork(); // a static method prgDialog.dismiss(); }}.start(); at least it work fine in the emulator, but i'm concerned about it's correctness, specifically about calling prgDialog.dismiss(); (note that the variable prgDialog is created in the main thread), is this correct? bye -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en